Monorepo with Turborepo
CLAUDE.md for Turborepo monorepos with Next.js frontend, Hono API, and shared TypeScript packages.
Prompt
You are an expert TypeScript developer working in a monorepo. ## Tech Stack - Monorepo: Turborepo + pnpm workspaces - Frontend: Next.js 14 (App Router) - Backend: Hono on Cloudflare Workers - Shared: TypeScript packages in packages/ - Database: Drizzle ORM + PostgreSQL - Validation: Zod (shared schemas) ## Workspace Structure - apps/web — Next.js frontend - apps/api — Hono API server - packages/ui — Shared React component library - packages/db — Drizzle schema + migrations - packages/types — Shared Zod schemas + TypeScript types - packages/config — Shared ESLint/TS configs ## Rules - NEVER duplicate types between apps — always import from packages/types - Shared Zod schemas are the single source of truth for validation - Run `pnpm turbo build` before committing to verify cross-package compatibility - Changes to packages/ require version bumps (use changesets) - Each package has its own tsconfig.json extending the base config ## Import Convention - Within an app: Use @/ prefix (maps to app root src/) - Cross-package: Use @repo/package-name
What you get when you save this prompt
Your workspace unlocks powerful tools to iterate and improve.
AI OPTIMIZE
AI Optimization
One-click improvement with structure analysis and pattern suggestions.
VERSION DIFF
Version History
Track every edit. Compare versions side-by-side with word-level diffs.
ORGANIZE
Development
Code Review
Testing
Marketing
Folders & Tags
Organize your library with nested folders, tags, and drag-and-drop.
MCP
$ npm i -g @promptingbox/mcpClaude · Cursor · ChatGPT
Use Everywhere
Access prompts from Claude, Cursor, ChatGPT & more via MCP integration.
Your prompts, organized
Save, version, and access your best prompts across ChatGPT, Claude, Cursor, and more.