2-phase design for `pnpm turbo gen core-ui-component`. Prompts for tier (atom/molecule/organism) + name (PascalCase) and emits the established 4-file component pattern (component.tsx, component.stories.tsx, component.test.tsx, index.ts) into the matching `packages/core-ui/src/<tier>s/` folder. Splices the new export into the tier barrel via `// <gen:<tier>s>` anchors. Phase A adds the anchors to the core-ui template's three tier barrels and regenerates the byte-identical reconstruction snapshot. Phase B ships the generator, templates, tests, and docs. Refuses to run if core-ui isn't scaffolded; doesn't touch Storybook config (existing stories glob covers new component stories). Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Clean Architecture Monorepo Template
Turborepo + pnpm monorepo organized by vertical features. See CLAUDE.md for the full conventions reference and AGENTS.md for the package map.
Quick Start
pnpm install # Install all dependencies
pnpm dev # Start all dev servers
pnpm build # Build all packages
pnpm test # Run all tests
pnpm turbo boundaries # Validate workspace dependency graph
pnpm turbo gen feature # Scaffold a new feature package
docker compose up -d # Start PostgreSQL
Optional packages
The default template includes the must-have core packages and all 5 feature packages. Four core packages are optional and scaffold on demand:
pnpm turbo gen core-package realtime # Socket.IO realtime layer (ADR-016)
pnpm turbo gen core-package events # Cross-feature events + Payload jobs (ADR-015)
pnpm turbo gen core-package trpc # tRPC server setup
pnpm turbo gen core-package ui # Design system
See docs/architecture/template-tiers.md for the full tier list.
Key ports
| Service | Port |
|---|---|
| Next.js | 3000 |
| Payload CMS | 3001 |
| TanStack Start | 3002 |
| PostgreSQL | 5432 |
| Storybook | 6006 |
Description
Languages
TypeScript
65.6%
JavaScript
21.1%
Handlebars
12.2%
Shell
0.9%
Dockerfile
0.1%