Skip to content

Migrated from root technical docs.

Use this guide for your first day in the repo.

  • apps/ — user-facing deployable entrypoints
  • workers/ — backend/runtime Cloudflare Workers
  • packages/ — reusable libraries and extracted feature slices
  • scripts/ — repo automation and deploy helpers
  • tests/ — cross-app and end-to-end verification
  • docs/ — canonical architecture, runbooks, ADRs, onboarding
  1. Install dependencies: pnpm install
  2. Start the dashboard: pnpm dev:dashboard
  3. Open http://localhost:5173
  4. Read ../../apps/README.md
  5. Read ../architecture/00-repo-map.md
  6. Read ../architecture/01-code-placement.md
GoalCommand
Start dashboardpnpm dev:dashboard
Start marketing sitepnpm dev:marketing
Start docs sitepnpm dev:docs
Start ingestion workerspnpm dev:ingestion
Start public API workerpnpm dev:worker-consumer-api
Run architecture checkspnpm ci:arch
Run repo validationpnpm validate
Deploy dashboardpnpm deploy:dashboard
Deploy marketing sitepnpm deploy:marketing

Use the canonical names above.

AreaPurposeEdit when…Common command
apps/dashboardMain product UI + server functionsyou are changing dashboard routes, pages, auth, or server functionspnpm dev:dashboard
apps/marketingPublic marketing siteyou are changing public site content or marketing pagespnpm dev:marketing
apps/docsPublic docs siteyou are changing published docs contentpnpm dev:docs
workers/*Cloudflare workers and operational servicesyou are changing queue consumers, public API, log processing, or rate limitingpnpm dev:ingestion, pnpm dev:worker-consumer-api
packages/feature-*Reusable dashboard feature data/UI sliceslogic is reused across dashboard screenspnpm ci:arch
packages/platform-*Cross-feature infrastructuremultiple features or apps need shared platform supportpnpm ci:arch
packages/domain-* / packages/utils / packages/dbShared domain and platform foundationslogic is framework-light or schema/data relatedpnpm ci:arch
tests/Cross-app/system verificationyou are adding or adjusting end-to-end coveragepnpm test:all
If you are adding…Put it here
Dashboard page compositionapps/dashboard/src/features/{domain}/pages/
Dashboard route declarationapps/dashboard/src/routes/{-$locale}/...
Reusable dashboard feature queries or mutationspackages/feature-{domain}/src/
Cross-feature platform logicpackages/platform-*
Shared business/domain rulespackages/domain-*, packages/utils, packages/db
Worker feature logicworkers/*/src/features/
Worker runtime adapters/binding accessworkers/*/src/infra/
Canonical docsdocs/architecture/, docs/runbooks/, docs/adr/

If you are unsure, stop and check ../architecture/01-code-placement.md.

Are you adding a deployable entrypoint?
YES -> Is it user-facing?
YES -> apps/
NO -> workers/
NO -> Is it dashboard-only page or route composition?
YES -> apps/dashboard/src/features or apps/dashboard/src/routes
NO -> Is it worker-runtime-specific (queues, D1 bindings, Durable Objects, wrangler-owned runtime)?
YES -> workers/*/src/features or workers/*/src/infra
NO -> Is it reused across multiple screens or multiple owners today?
YES -> packages/feature-* or packages/platform-*
NO -> Keep it with the current owning app/feature
  1. Find the owning worker under workers/*
  2. Keep runtime entrypoints thin
  3. Put domain logic in src/features/
  4. Put Cloudflare binding access and adapters in src/infra/
  5. Use the root canonical dev/deploy commands instead of memorizing local package names
  • Putting dashboard page composition into packages/feature-*
  • Putting Cloudflare runtime access into browser-safe layers
  • Using generic folders like helpers/, common/, or broad utils/ without a narrow owner
  • Assuming workers participate in the main Turbo app pipeline
  • Adding new production code to deprecated workers/my-api/
  • apps/dashboard, apps/marketing, and apps/docs are the main user-facing deployables and show up in the core Turbo workflow.
  • workers/* are still deployables, but they are operated through Wrangler-oriented scripts and worker-specific flows.
  • The repo is organized by deployable ownership, not by forcing every deployable into the same toolchain path.
Terminal window
pnpm scaffold dashboard-feature my-feature --route my-feature
pnpm scaffold domain-module my-domain
pnpm scaffold worker-feature worker-ingestion-process linking

Expected output paths:

  • pnpm scaffold dashboard-feature my-feature --route my-feature
    • apps/dashboard/src/features/my-feature/...
    • route files under apps/dashboard/src/routes/{-$locale}/(dashboard)/...
  • pnpm scaffold domain-module my-domain
    • packages/domain-my-domain/src/...
  • shared ingestion runtime modules
    • packages/platform-ingestion/src/features/notifications/...