nextjs-app-router-patterns

Guide Next.js 14+ App Router architecture with Server Components and streaming.

Updated Feb 23, 2026
One-click install
npx skills add https://github.com/pohlai88/AFENDA-NEXUS --skill nextjs-app-router-patterns-pohlai88
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: nextjs-app-router-patterns
Source: https://github.com/pohlai88/AFENDA-NEXUS/tree/main/.agents/skills/nextjs-app-router-patterns
Command: npx skills add https://github.com/pohlai88/AFENDA-NEXUS --skill nextjs-app-router-patterns-pohlai88

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Designers and developers often struggle to architect and implement modern Next.js 14+ App Router patterns, including Server Components, streaming, and advanced data fetching. This skill provides a consolidated guide to patterns, best practices, and real-world use cases to accelerate development and ensure scalable architecture.

Core Features & Use Cases

  • Pattern coverage for Server Components, Client Components, Streaming, Parallel Routes, Cache strategies, and Server Actions.
  • Practical guidance for file conventions, data fetching, routing, and SEO metadata.
  • Use cases include building new Next.js apps, migrating from Pages Router, and optimizing data fetching, SSR/SSG, and progressive enhancement.

Quick Start

Create a new Next.js project using App Router and implement a server component page that streams content with a parallel route setup.

Frequently Asked Questions about nextjs-app-router-patterns

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

FAQPage Schema
How do I migrate from the Next.js Pages Router to the App Router?

Migrating from the Next.js Pages Router to the App Router requires restructuring file conventions to use Server Components, updating data fetching logic, and defining new server-client boundaries for scalable architecture.

How do I fetch data and stream content with Next.js Server Components?

Next.js Server Components fetch data directly on the server and stream content to the client using partial prerendering and parallel routes, improving initial load performance without manual loading states.

What is the best way to structure routing and server-client boundaries in Next.js 14?

Structuring routing and server-client boundaries in Next.js 14 involves leveraging App Router file conventions, isolating Client Components, and using Server Actions to maintain progressive enhancement and optimal data flow.

Can I use parallel routes and route handlers for advanced data fetching in Next.js?

Yes, parallel routes and route handlers enable advanced data fetching in Next.js by allowing simultaneous rendering of multiple route segments and exposing API endpoints for complex full-stack React data flows.

How do I manage cache strategies and SEO metadata in a Next.js App Router project?

Manage cache strategies and SEO metadata in a Next.js App Router project by utilizing built-in caching mechanisms for data fetching and exporting dynamic metadata objects from layout and page files.

When should I use Server Actions instead of API routes in Next.js full-stack applications?

Use Server Actions instead of API routes in Next.js when handling form mutations and progressive enhancement directly within Server Components, reducing client-side JavaScript and simplifying server-client data mutations.