Circle V2 Developer Guide
Circle V2 is a ground-up rebuild of the CircleHealth application, focused on clean architecture, strong conventions, and a great developer experience.
This guide is split into focused documents so you can jump directly to what you need.
Table of Contents
- Introduction -- Project overview, tech stack, and high-level architecture.
- Getting Started -- Prerequisites, setup, environment variables, and common commands.
- Repository Structure -- Folder layout, apps, and the full package inventory.
- Package Conventions --
@repo/ scope, exports, import rules, and server-only boundaries.
- Web App Architecture -- App Router, authentication, providers, routing, and feature organization.
- Data Layer -- Drizzle schema, Kysely queries, the repository pattern, and branded IDs.
- tRPC -- Router structure, procedures, middleware, and client-side usage.
- Error Handling --
CircleError, Safe<T>, and error mapping conventions.
- UI and Components -- Chakra UI system, the component library, forms, and analytics.
- Code Style and Tooling -- Biome, import ordering, TypeScript configuration, and ESLint.
- Testing -- Vitest, Testing Library, database tests, and Playwright E2E.
- CI/CD -- GitHub Actions workflow, Turbo caching, and deployment.