Skip to content

Get started

Make a starter App with one command, serve it while you change it, check it the way CI will, and build it for production.

Terminal window
npx mistri new billing
cd billing
npm install
npx mistri dev

You need Node 24 or newer. The starter brings its own SQLite database, so nothing else has to be running. Starting from a schema of your own, or from a database you already have? Take an App from a schema or an App from your database instead.

Terminal window
npx mistri new billing
cd billing
npm install

You should now see the files it wrote: app.ts (the whole App), db/schema.sql and db/migrations/V1__task.sql (its schema, and how a database gets there), billing.db (that database, with a few rows), tablewalk.json (the connection the App binds), package.json, tsconfig.json, .oxfmtrc.json, .gitignore and a README.md that walks you through them. npm install brings in mistri, TypeScript and Node’s types.

Terminal window
npx mistri dev

You should now see the App’s address. Open it: the starter’s list, with rows in it. Leave the server running; a save reloads the App.

Open app.ts and change the App’s name:

export default defineApp({
id: 'billing',
name: "Billing desk",
// …

You should now see, after the save, the new name in the browser’s header, with no restart. The DSL tour shows what to add next, one key at a time.

In a second terminal, run what CI would:

Terminal window
npx mistri check --app . --config tablewalk.json

You should now see typecheck passed and validation passed, and an exit code of 0. A misspelled column or key is named with its file, its line and the fix (check codes).

Terminal window
npx mistri build --app . --config tablewalk.json

You should now see built … and the command that serves the build. A build is optional: it adds a pinned bundle and the checks, and build and deploy takes it into a container.