- Monorepo managed by Turborepo and pnpm
- Primary roots:
apps/,packages/,integrations/,docs/,e2e/ - Key services:
apps/web/(React/TypeScript)apps/api/(TypeScript + jsonnet)apps/relay/(Go)apps/workspace-engine/(Go)apps/workspace-engine-router/(Go)
- Use
pnpmfor Node/TypeScript work - Install dependencies with
pnpm install
pnpm build- Build all packagespnpm lint- Run ESLintpnpm lint:fix- Run ESLint with auto-fixpnpm format- Check formattingpnpm format:fix- Fix formattingpnpm typecheck- Type check all packagespnpm test- Run all testspnpm -F <package-name> test- Run tests for a specific packagepnpm -F <package-name> test -- -t "test name"- Run a specific test
- TypeScript: use explicit types, prefer interfaces for public APIs
- Imports: named imports, grouped by source (std > external > internal)
- Type imports:
import type { Type } from "module" - Prefer async/await over raw promises
- Use functional React components only (no class components)
- For React components, use
React.FCwith explicit typing, e.g.const My: React.FC = () => {} - Format with Prettier (
@ctrlplane/prettier-config) - Go: keep code gofmt-compliant, follow existing patterns in the package
- Promote the builder pattern for complex object construction and configuration
- For TypeScript packages, use the existing vitest setup
- For Go services, use
go testwithin the relevant module - Keep tests close to the code that changed when practical
- Keep changes focused and minimal
- Avoid editing generated files unless required
- If adding dependencies, use the package manager and latest versions