Gold Standard is an opinionated full-stack TypeScript monorepo starter.
It is designed to be a strong default for new projects: a practical baseline for monorepo layout, API contracts, schema ownership, auth flows, shared packages, and backend layering.
Instead of being just a demo app, Gold Standard is meant to answer questions like:
- How should a new feature/module be added?
- Where should contracts, schemas, services, and repositories live?
- How should frontend and backend types stay aligned?
- What does a clean full-stack TypeScript monorepo look like?
Gold Standard is currently a work in progress. The core structure is in place, but the template is still evolving as the conventions, tooling, and auth story are refined.
- Upgraded auth, either with Better Auth or a custom approach, with support for refresh tokens and social login
- Package versioning strategy using the pnpm catalog
- Test coverage for the template and its core flows
- A
pnpmworkspace managed with Turborepo - A full-stack TypeScript monorepo
- An opinionated starter for new monorepo-based products
- A reference implementation for typed APIs and shared contracts
- A project with first-class autogenerated Scalar/Swagger API docs baked into the backend
- A starter with a structured notifications layer, React Email templates, and Resend-based email delivery already wired in
apps/web: Vite + React frontendapps/api: Hono + oRPC backend
packages/api-schemas: shared Zod schemas for inputs and outputspackages/api-contract: shared oRPC contract definitionspackages/api-client: typed API client and TanStack Query helperspackages/auth-react: reusable client-side auth state utilitiespackages/db: Prisma schema, generated client, and DB access packagepackages/ui: shared UI components and styles
tooling/eslint: shared ESLint config package used across apps and packages via@workspace/eslint-configtooling/prettier: shared Prettier config package used across the workspace via@workspace/prettier-configtooling/typescript: shared TypeScript base configs used across apps and packages via@workspace/tsconfig
The backend already includes a structured notifications module instead of scattering email logic across feature services.
apps/api/src/infrastructure/notifications: typed notification events, channel renderers, transport registration, and the notification dispatcherapps/api/src/infrastructure/email: React Email templates, template rendering, and the Resend-backed email client
The current setup is designed so modules trigger notifications by event name and payload, while delivery stays transport-specific. Right now email is fully wired with React Email and Resend, and the notification layer is already shaped to support additional channels like SMS, WhatsApp, and push without changing feature-level orchestration.
A major part of this architecture is its built-in Scalar/Swagger documentation layer. The API docs are autogenerated from the oRPC contract and Zod schemas, and served live from the running backend at /api/docs. The machine-readable OpenAPI JSON spec is available at /api/spec.
This is not a separate docs project — it is part of the API contract itself, ensuring the API surface is always documented and discoverable.
Gold Standard favors a clear separation of concerns:
- Prisma models define persistence
- Zod schemas define API inputs and outputs
- API contracts define the transport surface
- Routers implement procedures
- Services hold business logic
- Repositories handle database access
That means new backend modules should generally follow:
procedure -> service -> repository -> prisma
-> dto mapper -> output schema
- Architecture
- Adding a new module
- API docs are available at
/api/docsand the OpenAPI JSON is available at/api/spec.
Install dependencies:
pnpm installRun everything in dev:
pnpm devCommon commands:
pnpm build
pnpm lint
pnpm lint:fix
pnpm check-types
pnpm db:generate
pnpm db:push- Gold Standard is intentionally opinionated: it optimizes for consistency, maintainability, and a clean developer experience.
- It is meant to be a starting point, not a rigid framework. Adapt it to your product, but keep the architectural boundaries deliberate.
- Several Turborepo-specific conventions and workspace patterns are inspired by t3-oss/create-t3-turbo.