nextjs-15

Apply Next.js 15 App Router patterns to project structure and component boundaries.

Updated Jan 15, 2026
One-click install
npx skills add https://github.com/estebandrg/liftera --skill nextjs-15-estebandrg
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: nextjs-15
Source: https://github.com/estebandrg/liftera/tree/main/skills/nextjs-15
Command: npx skills add https://github.com/estebandrg/liftera --skill nextjs-15-estebandrg

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

This Skill provides a structured approach for implementing Next.js 15 App Router patterns, clarifying how to organize app/, server components, server actions, route handlers, caching/revalidation, and streaming with Suspense.

Core Features & Use Cases

  • App Router conventions: layout.tsx, page.tsx, loading.tsx, error.tsx, not-found.tsx, route handlers, and API routes under app/.
  • Server Components vs Client Components: guidance on rendering strategy, data fetching, and interactivity.
  • Data fetching, caching, and streaming: techniques for parallel data fetching, suspense boundaries, and streaming UX.
  • Middleware and routing: patterns for conditional routing, route groups (like (auth)/) and protected routes.
  • Practical use case: build a multi-page dashboard with dynamic data and robust error handling using Next.js 15 App Router.

Quick Start

Follow these steps to explore App Router patterns in a Next.js 15 project:

  • Inspect the recommended file structure under app/
  • Review examples of layout.tsx, page.tsx, loading.tsx, and error.tsx
  • Check server actions, route handlers, and API routes in app/api

Frequently Asked Questions about nextjs-15

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

FAQPage Schema
How do I structure server components and client components in the Next.js 15 App Router?

To structure Next.js 15 App Router projects, define layouts and pages in the app/ directory, using server components by default and client components for interactivity. This separation enforces clear boundaries for data fetching and rendering.

What is the best way to implement streaming with Suspense in Next.js?

Streaming with Suspense in Next.js is implemented by wrapping dynamic components in Suspense boundaries within app/ layouts or pages. This enables parallel data fetching and progressively renders UI chunks to improve perceived loading performance.

How do I create API route handlers in a Next.js 15 app directory?

API route handlers in a Next.js 15 app directory are created by defining route.ts files inside the app/api/ folder. These route handlers process incoming HTTP requests and return responses, functioning as backend endpoints within your application structure.

When should I use server actions instead of API route handlers in Next.js?

Server actions in Next.js should be used for mutations and form submissions directly within server components, whereas API route handlers are better for external API consumption. Server actions streamline data mutations without creating separate API endpoints.

How do I configure middleware for protected routes using Next.js route groups?

Configuring middleware for protected routes using Next.js route groups involves defining conditional routing logic in middleware.ts and organizing authenticated sections into folders like (auth)/. This pattern secures specific application areas globally.

Why do I need loading and error boundaries in a Next.js App Router project?

Loading and error boundaries are needed in a Next.js App Router project to handle streaming states and unexpected failures gracefully. Using loading.tsx and error.tsx files ensures robust UI fallbacks during data fetching and runtime errors.