ADR-0010 — pnpm workspace with an in-repo design system
Status: Accepted (implemented 2026-10-10, DS-0)
Context
The civic redesign (docs/identity/brief.md) asks for a reusable design system rather than a collection of styled pages, and the plan builds that system before the site. The black hole, previously the site’s background, is to become a standalone project. Three bodies of code now have different lifecycles inside one repo.
Decision
Convert the repo to a pnpm workspace:
apps/site: the Astro site.packages/ds(@400/ds): tokens, CSS, Vue components. Source-only: consumers import.ts/.vuedirectly and their bundler compiles them, so there is no DS build step. The one generated artifact (CSS from tokens) is committed and checked fresh in CI.packages/black-hole: the renderer, parked until extracted (plan §6).
Alternatives considered
- Separate DS repo, published package: versioning and release ceremony for one consumer. Rejected until a second consumer exists.
- DS as a folder inside the site: no boundary. Site code would reach into DS internals and the “DS first” ordering couldn’t be enforced.
Consequences
- Root scripts delegate (
pnpm dev/build→ site,pnpm check→ every package). - CI deploys from
apps/site. The worker is renamed400-wtf-nextso the fork never deploys over the live site.