bundles/frontend/skills/nextjs-validator/SKILL.md
Validate Next.js 16 configuration and detect/prevent deprecated patterns. Ensures proxy.ts usage, Turbopack, Cache Components, and App Router best practices. Use before any Next.js work or when auditing existing projects.
npx skillsauth add shipshitdev/library nextjs-validatorInstall this skill globally with one command. Works with Claude Code, Cursor, and Windsurf.
3 of 9 scanners reported clean
Some scanners were skipped, did not run, or reported a non-clean status. Review each row below.
Validates Next.js 16 configuration and prevents deprecated Next.js 14/15 patterns.
python3 scripts/validate.py --root .
python3 scripts/validate.py --root . --strict
// GOOD: v16+
"next": "^16.0.0"
// BAD: v15 or earlier
"next": "^15.0.0"
GOOD - Next.js 16:
// proxy.ts (Node.js runtime - REQUIRED)
import { createProxy } from 'next/proxy';
export const proxy = createProxy();
BAD - Deprecated:
// middleware.ts (Edge runtime - DEPRECATED)
export function middleware() { }
GOOD:
app/
├── layout.tsx # Root layout
├── page.tsx # Home page
├── (routes)/ # Route groups
│ ├── dashboard/
│ │ └── page.tsx
│ └── settings/
│ └── page.tsx
└── api/ # API routes (optional)
BAD - Pages Router (deprecated):
pages/
├── _app.tsx
├── index.tsx
└── api/
use cacheGOOD - Next.js 16:
// app/dashboard/page.tsx
'use cache';
export default async function Dashboard() {
const data = await fetch('/api/data');
return <DashboardView data={data} />;
}
GOOD:
// app/actions.ts
'use server';
export async function createItem(formData: FormData) {
// Server-side logic
}
GOOD - Default in Next.js 16:
// next.config.ts (Turbopack is default, no config needed)
BAD - Disabling Turbopack:
// Don't disable unless absolutely necessary
experimental: {
turbo: false // BAD
}
GOOD - TypeScript config:
// next.config.ts
import type { NextConfig } from 'next';
const config: NextConfig = {
// ...
};
export default config;
BAD - JavaScript config:
// next.config.js - Prefer .ts
module.exports = { }
| Deprecated (v15-) | Replacement (v16+) |
|-------------------|-------------------|
| middleware.ts | proxy.ts |
| getServerSideProps | Server Components + use cache |
| getStaticProps | Server Components + use cache |
| getStaticPaths | generateStaticParams |
| _app.tsx | app/layout.tsx |
| _document.tsx | app/layout.tsx |
| pages/ directory | app/ directory |
| next/router | next/navigation |
| useRouter() (pages) | useRouter() from next/navigation |
'use cache';
// Entire component cached
export default async function CachedPage() {
const data = await fetchData();
return <View data={data} />;
}
// next.config.ts
const config: NextConfig = {
experimental: {
ppr: true,
},
};
AI-assisted debugging with contextual insight:
// Enable in development
// Works with MCP-compatible agent tools
app/
├── @modal/
│ └── login/
│ └── page.tsx
├── @sidebar/
│ └── default.tsx
└── layout.tsx
See references/full-guide.md (§ Intercepting Routes Example) for the directory layout.
See references/full-guide.md (§ Validation Output Example) for a sample report.
See references/full-guide.md (§ Migration Guide) for before/after examples of migrating middleware.ts → proxy.ts and getServerSideProps → Server Components.
# .github/workflows/validate.yml
- name: Validate Next.js 16
run: |
python3 scripts/validate.py \
--root . \
--strict \
--ci
tailwind-validator - Validate Tailwind v4 configbiome-validator - Validate Biome 2.3+ configclerk-validator - Validate Clerk auth setupdevelopment
Coordinates a weekly engineering review of board accuracy, recent code changes, operational health, and scoped cleanup. Use for a recurring repository health review or a review of the last several days.
testing
Audits project board configuration and prepares explicitly requested setup, copy, or normalization changes while preserving the existing workflow and provider boundaries. Use when inspecting a board's fields, columns, scope, or configuration.
testing
Reconciles a project board with current work and delivery evidence, reports incomplete coverage and metadata gaps, and applies only approved provider-supported field changes. Use when auditing board drift, reviewing blocked work, or assessing upcoming delivery.
development
Walk through how a subsystem works. Use for "how does X work", code walkthroughs before changing something, and placement or ownership questions. Explains architecture, runtime flow, and onboarding mental models. Can critique architecture. Use why for motivation.