PROJECT-STRUCTURE

Configure Next.js 16 and React 19 projects with App Router and TypeScript.

2|2|Updated Feb 9, 2017
One-click install
npx skills add https://github.com/sumik5/dotfiles --skill project-structure-sumik5
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: PROJECT-STRUCTURE
Source: https://github.com/sumik5/dotfiles/tree/main/claude-code/skills/developing-nextjs/PROJECT-STRUCTURE.md
Command: npx skills add https://github.com/sumik5/dotfiles --skill project-structure-sumik5

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This document outlines a scalable Next.js project structure with conventions for app router, API routes, Prisma, and testing.

Core Features & Use Cases

  • Directory layout: Clear separation of app, api, lib, and tests.
  • Naming conventions: Consistent, scalable patterns for components and pages.
  • Tooling integration: Aligns with mise and tooling standards.

Quick Start

Initialize a new Next.js project following the recommended structure.

Frequently Asked Questions about PROJECT-STRUCTURE

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I structure a Next.js project with App Router and Prisma?

Next.js project structure separates app routes, API endpoints, library utilities, and tests into distinct directories. This Skill provides a scalable layout with clear conventions for App Router, Server Components, and Prisma ORM integration, enabling maintainable codebases as your application grows.

What naming conventions should I follow for Next.js components and pages?

Consistent naming conventions ensure scalability and readability across your Next.js codebase. This Skill covers recommended patterns for components, pages, and API routes that align with App Router standards and TypeScript strictness, reducing friction when onboarding developers.

How do I configure TypeScript, ESLint, and Tailwind CSS in a Next.js project?

Modern Next.js projects require coordinated tooling configuration across tsconfig.json, eslint.config.mjs, and Tailwind CSS v4. This Skill integrates these configurations with mise.toml for reproducible environments and strict type safety enforcement throughout your project.

Can I use Server Components and Prisma together in Next.js 16?

Yes. Next.js 16 with React 19 enables Server Components for direct database queries via Prisma ORM, eliminating unnecessary API layers. This Skill demonstrates server-first design patterns and performance optimization strategies that leverage these capabilities together.

What testing setup works with Next.js and this project structure?

Vitest integrates with Next.js project layouts for fast, type-safe unit and integration testing. This Skill covers test directory organization and configuration aligned with your App Router structure, supporting code quality improvements and confidence in refactoring.

Why should I separate API routes, app routes, and utilities into different directories?

Separation of concerns improves maintainability, testing, and collaboration. Distinct directories for API routes, application pages, shared libraries, and tests clarify ownership and dependencies, making your Next.js codebase easier to navigate and modify as it scales.