Weiv is a framework for building web pages with TypeScript. A .weiv file keeps
its markup, code, and styles together. Changing a value updates the page.
Weiv is available to try and is still before its first stable release. The
published compiler supports macOS arm64, Linux x64 GNU, and Windows x64 GNU.
For another platform, provide a compatible binary through WEIV_BINARY_PATH.
Install Weiv in a Node.js project:
npm install --save-dev weivjsCreate App.weiv:
<template>
<button @click="increment">Count: {{ count }}</button>
</template>
<script lang="ts">
let count = 0;
function increment() {
count += 1;
}
</script>Run the page locally:
npx weiv dev App.weivFor a static bundle, run npx weiv compile App.weiv. Weiv writes the result to
dist/; use bun dist/server.ts to serve it.
The package also provides adapters at weivjs/vite and weivjs/bun. See the
package guide for those integrations.
