Local setup
Install the workspace, set the rules channel, run the app with demo data, and know which commands exist.
You can run the whole product on a laptop with no services: the app keeps its data in the browser and seeds a demo firm on first load.
Before you start
- pnpm. The root
package.jsonpinspackageManagerto pnpm 11. With Corepack enabled,pnpmpicks the right version. - Node. CI runs Node 24. The engine's scripts run TypeScript files directly (
node scripts/release.ts), so use a Node version that strips types without a flag. Node 24 does.
Install and run
pnpm install
cp apps/web/.env.example apps/web/.env.local
pnpm dev # turbo dev → next dev on http://localhost:3000- Open http://localhost:3000.
/is the static marketing site (rewritten topublic/index.html). The app is at/app. - Sign in with a demo account.The sign-in page lists the demo accounts for Northwind CPA LLP: Amara Chen (owner), Olivia Martin (admin), Jordan Patel (preparer) and Marie Tremblay (reviewer). Other email addresses are refused.
- Switch users to test permissions.The account menu has Switch user (prototype sign-in). The seed also has Sam Rivera, owner of a second firm, for tenant-isolation checks.
- Reset when you need a clean slate.Reset demo data… in the account menu restores the seed (
resetDemo()inlib/store.ts).
Environment variables
All variables are NEXT_PUBLIC_*. Next inlines them at build time, so restart pnpm dev after a change.
Every release, including 2026.1, is a draft. With the channel unset (production), formSetFor finds no selectable release and new returns can't be created. Keep NEXT_PUBLIC_RULES_CHANNEL=dev in .env.local.
Commands
Root scripts run through Turborepo across the workspace:
pnpm dev # all dev servers (the web app on :3000)
pnpm build # production build
pnpm typecheck # tsc --noEmit in each package
pnpm lint # eslint --max-warnings 0 in each package
pnpm test # vitest in each package
pnpm test:e2e # Playwright, via pnpm --filter web test:e2eEngine scripts (packages/t2/package.json):
pnpm --filter @workspace/t2 test # engine, scenarios, releases
pnpm --filter @workspace/t2 calc-hash # after editing any calculation file
pnpm --filter @workspace/t2 report # regenerate the generated docs
pnpm --filter @workspace/t2 release … # new | diff | publish | check
pnpm --filter @workspace/t2 cra-update # look for CRA and statute changes
pnpm --filter @workspace/t2 cra-rules # compile the CRA Error Code List
pnpm --filter @workspace/t2 catalogue # rebuild the form catalogueWeb scripts (apps/web/package.json): test (vitest), test:e2e (Playwright), test:walk (the slow walk-through project), lint, typecheck and format.
Run one full test suite at a time and keep vitest at --maxWorkers=2. Parallel full runs of vitest and tsc have exhausted memory on a laptop. Run a single file while you work: npx vitest run test/docs.test.ts --maxWorkers=1 from apps/web.
Troubleshooting
Related
- ArchitectureSee how the web app, the tax engine and the UI kit fit together, where state lives, and what the prototype leaves out.
- ConventionsFollow the house rules for Next 16 code, the design system, money and ids, user-facing text and finishing UI work.
- TestingRun the engine, web and Playwright suites, know what each covers, and add the right tests for a change without overloading your machine.