dallin/t3-app-router-repo-structure icon
public
Published on 4/7/2025
dallin/t3-app-router-repo-structure

Repo structure for a t3 Stack Next.js App Router

Rules

Codebase structure (non-exhaustive, excluding common config etc files): ├─ prisma │ └─ schema.prisma (db schema) ├─ public (static assets) ├─ src │ ├─ app │ │ ├─ _components (shared components) │ │ ├─ api (routes including next auth) │ │ ├─ layout.tsx │ │ └─ page.tsx │ ├─ server │ │ ├─ auth.ts │ │ ├─ db.ts │ │ └─ api │ │ ├─ routers (backend endpoints) │ │ │ └─ example.ts │ │ ├─ trpc.ts │ ├─ env.js (typesafe env) │ └─ trpc (trpc config/setup)