Project structure · Full stack
Turborepo monorepo project structure
Opens with creditsOne Git repository holding several apps and the packages they share, wired together by pnpm workspaces and run by Turborepo. apps/ holds things you deploy (two Next.js apps from the starter, later an API), packages/ holds shared code and config (UI components, ESLint and TypeScript configs, validation schemas, the database client). Turborepo runs each task in dependency order and caches the results, so you never rebuild what did not change.
How it grows
Each stage opens the explorer there
- 1Day 1What the scaffold and your first hour give you66 files and folders
- 2GrowingWhat a real app with features and tests adds+41 files and folders
- ProductionWhat running it for real users adds+20 files and foldersOpens with credits
- ExpertWhat a team needs to keep it healthy for years+19 files and foldersOpens with credits
How it is organised
- `apps/` is for things you deploy; `packages/` is for things apps share. An app never imports from another app.
- Every package declares what it uses in its own package.json, with internal ones as `workspace:*`. Install dependencies where they are used, not at the root.
- Each package exposes a small public surface through its `exports` map. Importing a deep path or reaching into another package's folder is a bug.
- Start with just-in-time packages (export TypeScript source, let the app compile it). Add a build step only for packages you publish or that a non-bundler tool must read.
- Every task an app or package runs is a script in its package.json and a task in turbo.json. Declare `outputs` so cache hits restore files, `env` so cache keys include the variables a build reads, and `cache: false` for anything with side effects.
- Configuration is shared through packages (`@repo/eslint-config`, `@repo/typescript-config`, `@repo/vitest-config`), so one pull request changes the rules everywhere.
- CI runs the same turbo commands you run locally, with `--affected` and a remote cache, so the time a pull request takes grows with the change, not with the repo.
- At Expert, boundaries are enforced, not hoped for: package tags and `turbo boundaries`, CODEOWNERS per folder, contract tests between apps.
At the top of the project
Open one in the explorer for the full story
- my-turborepo/
- .git/Git history. create-turbo commits "Initial commit from create-turbo" on a main branch.
- .turbo/Turborepo's local cache, logs and daemon files.
- .vscode/Shared editor settings for the whole repo.1 inside
- .gitignoreIgnores node_modules, env files, coverage, .turbo, .vercel, .next, out, build and dist.
- .npmrcEmpty in the example. Recent pnpm reads its settings from pnpm-workspace.yaml instead.
- .nvmrcPins Node.js 24, matching `engines` in the root package.json.
- AGENTS.mdInstructions for AI coding agents: read the docs bundled with the installed turbo version first.
- README.mdThe starter readme: what is inside, how to build, develop and use remote caching.
- apps/Deployable applications.3 inside
- docker-compose.ymlPostgreSQL 18 (and later Redis) for local development of every app.
- node_modules/Installed packages for the whole workspace, with symlinks to internal packages.
- package.jsonThe root: scripts that call turbo, root dev tools, `packageManager` and `engines`.
- packages/Internal packages: shared code and configuration that apps (and other packages) depend on.6 inside
- pnpm-lock.yamlThe single lockfile for every package in the workspace.
- pnpm-workspace.yamlDeclares which folders are workspace packages: `apps/*` and `packages/*`.
- turbo.jsonThe task graph: which tasks exist, what they depend on, their outputs, env vars and caching.
- turbo/Turborepo generators for creating new packages and components in the house style.1 inside
Learn more on Sefism
Roadmaps, cheat sheets and projects that go with Turborepo monorepo.
- Roadmap· Next.js and PostgreSQLFull stack development roadmapBuild and ship whole web apps
- RoadmapDevOps and cloud roadmapLinux, Docker, Kubernetes, AWS
- RoadmapLinux, terminal and Git roadmapShell, Git, SSH and your dev setup
- Roadmap· ReactFrontend development roadmapHTML, CSS, JavaScript and a framework
- Cheat sheetFull stack development cheat sheetBuild and ship whole web apps.
- Cheat sheetDevOps and cloud cheat sheetLinux, Docker, Kubernetes, AWS.
- Cheat sheetLinux, terminal and Git cheat sheetShell, Git, SSH and your dev setup.
- FYP idea· AdvancedDependency Upgrade Impact Checker That Finds Which of Your Calls a Breaking Change HitsBuild a tool for TypeScript projects that compares the public API of two versions of an npm package, finds the breaking changes, then searches your own code for the exact call sites they affect. Dependabot and Renovate open upgrade pull requests but cannot say whether a major version bump touches anything you use. This tool answers that question with a list of files and lines, so small teams stop putting off upgrades.
- FYP idea· IntermediateFlaky Test Detector for GitHub Actions That Uses Change Coverage Instead of RerunsBuild a CI tool that decides whether a failing test is flaky without rerunning it, by checking whether the failing test executed any of the code the commit changed. A test that fails without touching the change is almost certainly flaky. The tool labels failures on pull requests, tracks flaky tests over time and saves the CI minutes that blanket reruns waste.
See 9 moreShow fewer
- FYP idea· IntermediateSigned Build Provenance Gate for a Company's Internal Packages and Container ImagesBuild a gate that lets a small company prove every internal package and container image was built by its own CI from a reviewed commit, and blocks anything that was not. It uses keyless signing from the Sigstore project and SLSA-style provenance, wrapped into a setup a team can adopt in an afternoon. Deployments and installs check the signature and the build record before they proceed.
- QuestionHow do I learn to read a large codebase when I can handle small projects but get lost in real ones?Nobody reads a large codebase from top to bottom. You follow one real path through it, such as a single request or button click, from entry point to database and back. Map what you find, ignore everything off that path for now, and repeat with a different path. Understanding builds in layers, and a first small change teaches more than a week of reading.
- QuestionHow do I learn Git and GitHub properly instead of just copying commands?Learn the model first: commits are snapshots, branches are pointers, and remotes are copies. Then use Git daily on your own projects, practise a team workflow with branches and pull requests, and break things on purpose, such as merge conflicts, so you learn to recover calmly.
- QuestionDo I need Docker and Kubernetes as a junior developer?Docker, yes: learn the basics, because nearly every team uses containers and you will be expected to run the project locally and read a Dockerfile. Kubernetes, mostly no: understand what it does and a few core terms, but deep Kubernetes can wait until your job or a DevOps direction needs it.
- Resource· GuideNext.js DocumentationThe official Next.js documentation covers the React framework's App Router and the older Pages Router: routing and layouts, server and client components, data fetching, caching (including Cache Components), server actions, route handlers, Proxy (formerly middleware), streaming, Turbopack and deployment. Next.js Learn teaches one app step by step; these docs are the reference to keep open once you build your own. It suits React developers building production apps with Next.js.
- Resource· GuideThe TypeScript HandbookThe TypeScript Handbook is the official, free guide to TypeScript's type system from the TypeScript team, written for working programmers and kept current with each release. It covers everyday types, narrowing, functions, object types, generics, type manipulation, classes and modules, and it is designed to be read in a few hours. It suits JavaScript developers adopting TypeScript and anyone who writes types by copying patterns without understanding them.
- Resource· GuideGitHub Actions DocumentationThe official documentation for GitHub Actions, GitHub's built in CI/CD and automation system: workflow syntax, triggers, runners, caching, artifacts, environments, secrets and OpenID Connect deployments to AWS, Azure and Google Cloud. Actions is free for public repositories on standard runners, so it is the CI tool most students and open source projects learn first. It suits developers setting up tests and deployments for the first time.
- Resource· GuideDocker Docs: Get StartedDocker's official starting point: install Docker, follow a tutorial that builds, runs and shares a containerised application, then work through short concept pages on containers, images, registries, Compose, image layers, Dockerfiles, the build cache, multi-stage builds, ports and persistent data. It suits developers who have heard of containers but never used them, and it is current, free and more accurate than most tutorials copied from it.
- Resource· GuideVitest DocumentationThe official documentation for Vitest, the test runner built on Vite. Its getting started guide has you writing and running a real test in minutes, then covers matchers, async tests, setup and teardown, mocking (functions, modules, timers, dates, requests), snapshots, coverage, the UI dashboard and browser mode for component tests. It uses a Jest-compatible API, so it suits JavaScript and TypeScript developers starting to test, and teams moving from Jest.
Checked against 18 official sources, October 2026. If something has changed, the docs win.Show sourcesHide sources
- Turborepo: Installation and create-turbo
- Turborepo: Structuring a repository
- Turborepo: Internal packages
- Turborepo: Configuring tasks
- Turborepo: Using environment variables
- Turborepo: Constructing CI
- Turborepo: Package configurations
- Turborepo: turbo prune and Docker
- Turborepo: turbo boundaries
- Turborepo: Generating code
- Turborepo: Vitest and Playwright guides
- Turborepo: Publishing libraries (Changesets)
- Turborepo basic example
- pnpm: Workspaces
- pnpm: Catalogs
- Prisma: Using Prisma with Turborepo
- Changesets
- Hono: Node.js
Best practices and checklists for this stack
Picked from the other libraries by shared topics.
Best practices
See all- TypeScript Best PracticesModern TypeScript best practices for 2026: strict settings, TypeScript 7, modeling data with unions, safe narrowing, runtime validation, generics and typed linting.
- Next.js App Router Best PracticesNext.js 16 App Router best practices: Server Components, Cache Components and use cache, secure Server Actions, proxy.ts, metadata and images.
- React Best PracticesModern React best practices for 2026: pure components, lean state, fewer effects, React Compiler, form actions, accessibility and testing.
Checklists
See all- Web Accessibility ChecklistA practical web accessibility checklist built on WCAG 2.2 level AA, with a severity and a concrete way to verify every check.
- Web Performance ChecklistA practical web performance checklist built on Core Web Vitals: LCP, INP and CLS, with a severity and a concrete way to verify every check.
- Web Application Security ChecklistA practical web application security checklist built on the OWASP Top 10:2025 and ASVS 5.0, with a severity and a way to verify every check.
Stuck on something specific?
Writing only gets you so far. If you want an answer to your situation rather than the general case, book a session and we will work through it together. Sessions are free for approved Sefism members, and a few slots open each week.
- 1:1 Mentorship
- Fresh Graduate Mentorship
- Career Guidance
Brand deals, promos and partnerships: tauseeffayyaz@gmail.com