Begin

Quick start

Create an App from the official starter with pnpm create ajo and run it locally.

Ajo holding a small glowing lantern, lighting the way.

pnpm create ajo creates a working App from the official starter, Ajo Notes: a small private notebook with accounts, SQLite and live updates, built with Ajo, Kit, ajo-kit-auth, ajo-kit-mail and Playa. You need Node 22.18 or newer and pnpm. Node is only the development host; production runs on Ajo Engine.

Create the App

Terminal
pnpm create ajo notes

The directory must be new or empty. The command copies the starter into it and names the project after the directory, runs git init when Git is installed and the directory is not already inside a repository, and installs the dependencies. Then it runs the starter’s setup, which writes a private .env (mode 0600) with a generated APP_SECRET and applies the migrations to ./database.sqlite. Every Ajo package is pinned to the release that create-ajo was published with.

Run it

Terminal
cd notes
pnpm kit dev

Kit starts a Vite development server on http://localhost:5173. Create an account and add a note, then open /notes in a second tab to watch changes arrive. In development, a mailbox on the notes page captures messages instead of contacting an email provider. Edit a page or layout and it updates in place.

What the starter contains

PathWhat it does
package.jsonThe scripts, exact dependency versions and the kit.engine block: the data directory and the optional mail variables.
pnpm-workspace.yamlAllows the install scripts of argon2 and esbuild, and no others.
vite.config.ts, uno.config.tsRegisters the kit() plugin, keeps the database and mail modules out of the browser, and styles the pages with Playa.
tsconfig.jsonCompiles JSX to Ajo and type-checks the project strictly.
index.htmlThe document, with the three ssr: slots Kit fills on every server render.
src/layout.tsx, src/page.tsxThe header every page shares and the public welcome page at /.
src/wares.tsLoads the mail setup and runs the session and CSRF middleware.
src/(account)Registration and sign-in forms and actions behind a guest guard.
src/notesA protected loader, owner-scoped actions, live data and the development mailbox.
src/verify/[signature]Checks the signed, expiring link that verifies an email address.
src/database.tsA typed schema combining the auth tables with the notes.
src/mail.tsCaptures mail in development. In production it uses an HTTP provider, or leaves mail off until its variables are set.
db/migrations/0001_notes.tsThe notes table, its owner foreign key and an index, with up and down.
scripts/setup.mjsThe setup that pnpm create ajo ran. Run again, it keeps an existing .env.
testsHTTP tests for accounts, notes and mail, migration tests and a browser journey.

The project’s README.md explains each of these, the environment variables, the tests, the production build and the first deploy. Routing, Loaders, Actions and Live updates describe the conventions the files follow.

Where to go next