A modern monorepo starter template using pnpm workspaces, Turborepo, and Changesets.
- 📦 pnpm - Fast package management
- 🏎️ Turborepo - High-performance build system
- 🚢 Changesets - Versioning and publishing
- 🧹 Husky - Git hooks
- 📝 commitlint - Enforce conventional commits
- 🛡️ ESLint - Code linting with shared configurations
- 🔄 TypeScript - Shared TypeScript configurations
- 🎨 Prettier - Code formatting with shared configurations
- Node.js 22.x
- pnpm 10.5.2+
monorepo-starter/
├── apps/ # Application packages
│ ├── web/ # Next.js web application
│ └── storybook/ # Storybook UI component documentation and playground
├── packages/ # Shared packages, libraries, and utilities
│ ├── typescript-config/ # Shared TypeScript configurations
│ ├── eslint-config/ # Shared ESLint configurations
│ ├── prettier-config/ # Shared Prettier configurations
│ └── ui/ # Shared UI component library
├── .changeset/ # Changeset files
├── .github/ # GitHub related files (workflows, templates, etc.)
├── .husky/ # Git hooks configuration
├── .vscode/ # VS Code settings
├── .turbo/ # Turborepo cache
├── LICENSE # License file
├── .gitignore # Git ignore file
├── .node-version # Node.js version
├── .npmrc # npm configuration
├── commitlint.config.js # Commitlint configuration
├── package.json # Root package.json
├── pnpm-lock.yaml # pnpm lock file
├── pnpm-workspace.yaml # pnpm workspace configuration
└── turbo.json # Turborepo configuration
# Clone and install
git clone https://github.com/yourusername/monorepo-starter.git
cd monorepo-starter
pnpm install
# Development
pnpm dev # Start development servers
pnpm build # Build all packages
pnpm test # Run tests
# Code Quality
pnpm lint # Run linting
pnpm lint-staged # Run staged files linting
pnpm check-types # Type checking
pnpm format # Format code
# UI Components
pnpm add-ui -- [component...] # Add shadcn UI components to the UI library
- pre-commit: Runs type checking and linting on code
- commit-msg: Validates commit messages
Follow the Conventional Commits specification:
<type>(<scope>): <subject>
Common types: feat
, fix
, docs
, style
, refactor
, perf
, test
, build
, ci
, chore
# Interactive commit prompt
pnpm commit
# Manual commit
git commit -m "type(scope): subject" -m "description"
# Create a changeset
pnpm changeset
# Version packages
pnpm changeset version
# Publish packages
pnpm publish-packages
- Create a directory in
apps/
orpackages/
- Initialize your application/package
- Add to workspace in package.json
MIT License - see the LICENSE file for details.