Local development and load tests
Run it locally
Section titled “Run it locally”pnpm installcp .dev.vars.example .dev.vars # fill in the valuespnpm db:migrate:localpnpm dev| Command | Purpose |
|---|---|
pnpm test |
Vitest inside the Workers runtime (@cloudflare/vitest-plugin) |
pnpm typecheck |
TypeScript 7 |
pnpm lint |
oxlint with type-aware rules |
pnpm format |
oxfmt |
pnpm check |
All of the above |
pnpm cf-typegen |
Generate worker-configuration.d.ts again after changes to wrangler.jsonc |
Load tests with simulated calendars
Section titled “Load tests with simulated calendars”This variable replaces Graph and Google with simulated calendars inside the Durable Objects:
pnpm wrangler dev --var DEV_FAKE_CALENDARS:1 --var DEV_FAKE_LATENCY_MS:80Signed in as an admin:
POST /dev/seed?accounts=10&events=200creates ten accounts in the block group.POST /dev/cyclestarts a sync cycle.GET /dev/statscounts runs, writes and provider calls.
Without the variable, the /dev routes do not exist.
The website
Section titled “The website”The website and these docs are an Astro site with Starlight in website/:
pnpm --filter website devpnpm --filter website buildContributing
Section titled “Contributing”CONTRIBUTING.md explains the setup, the commit format and pull requests. Report vulnerabilities privately, see SECURITY.md.