nextjs-conventions · git:20261014.c8129da · 2026-10-14 · sha256 efb453b190ad9aa4

nextjs-conventions git:20261014.c8129daA

Immutable. This exact content never changes and is served at /api/v1/blob/efb453b190ad9aa4.

No tool to install first
claude plugin marketplace add https://markdownregistry.com/mp/a/art_4scpqsy4dypy3cz6/efb453b190ad9aa4c5b2cc44db831a8009e032ad14707b6b72e6e961995bc93f.json

Then /plugin install nextjs-conventions@markdownregistry-4scpqsy4dypy3cz6 in Claude Code. It installs this exact version, the one graded A here, pinned to the commit it was graded at, and leaves it there.

---
name: nextjs-conventions
description: Apply Next.js conventions for schema-validated input, Server Components by default, Server Actions with typed results, forward-only migrations, and consented analytics. Use when writing or reviewing Next.js app code or next.config files.
---

# Shared Next.js and web conventions

- Validate every input from forms and APIs with a schema validator (for example Zod with `.safeParse()`).
- Default to Server Components. Use `'use client'` only for state or event handling.
- Prefer Server Actions over API routes when possible. Return `{ ok: true, data? } | { ok: false, error }`.
- Follow the project's migration policy; if it declares none, write forward-only migrations.
- Route analytics calls through the project's tracking wrapper when one exists, behind a consent gate where the platform requires consent.