AerialDB is a SvelteKit 5 application for cataloging aerial acrobatics moves. It uses Drizzle ORM with SQLite locally, Cloudflare D1 in production, and Cloudflare R2 for image uploads.
- SvelteKit 2 + Svelte 5 runes
- TailwindCSS v4
- Drizzle ORM over SQLite/libsql and Cloudflare D1
- Custom session auth with SHA-256 session tokens and Scrypt password hashes
- Paraglide JS i18n with messages in
messages/en.jsonandmessages/es.json - Vitest, Playwright, and
vitest-browser-svelte
Use npm for this project. .npmrc enables engine-strict, and package.json requires Node.js 18 or newer.
npm install
cp .env.example .env
npm run db:init
npm run devMinimum local environment:
DATABASE_URL=file:local.dbProduction image uploads also require PUBLIC_R2_URL.
npm run dev
npm run check
npm run lint
npm run test:unit -- --run
npm run test:e2e
npm run buildDatabase commands:
npm run db:push
npm run db:generate
npm run db:migrate
npm run db:seed
npm run db:initdb:init initializes a local database from scripts/init-db.ts. db:seed runs the TypeScript seeding utility at src/lib/server/db/seed.ts.
AGENTS.md- full coding-agent guidelines, conventions, and route mapmdocs/PROJECT_INDEX.md- current project index for humansmdocs/PROJECT_INDEX.json- current project index for toolssrc/routes/api/README.md- API endpoint contractssrc/lib/components/README.md- shared component registrymdocs/TOON_FORMAT.md- custom.toonimport format.Jules/sentinel.md- security and reliability lessons learned
The app builds for Cloudflare Pages via @sveltejs/adapter-cloudflare. Bindings are declared in wrangler.toml:
DBfor Cloudflare D1IMAGESfor Cloudflare R2
See mdocs/CLOUDFLARE_DEPLOYMENT.md for deployment details.