/engineering-paved-path:react-best-practicesfrom engineering-paved-path
Modern React best practices and anti-pattern catalog (2025-26). Use when writing, reviewing, or refactoring React components, hooks, and state management. Covers component design, state patterns, hooks misuse, performance, data fetching, and code organization.
Ships in engineering-paved-path. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Modern React conventions (2025-26). Covers what to do and what to avoid. For code examples, see examples.md.
Each rule is tagged with a severity for use by consuming agents:
children prop and composition over deep prop drillingThe #1 React anti-pattern. Look for it in every review.
useState — compute during renderuseState + useEffect to sync a computed value — just compute ituseMemo ONLY if the computation is expensive (measured, not assumed)useState — only values that change over time and affect the UIuseReducer instead of multiple useState callsBefore each useEffect, ask: Is there an external system being synchronized? If no, it's misused.
useEffect for derived state — compute during renderuseEffect for event handling — put logic in the event handleruseEffects that trigger each other — usually means derived stateMost useMemo/useCallback calls are unnecessary. Be skeptical:
useMemo — only for actually expensive computations (sorting large datasets, complex transforms)useCallback — only when the function is passed to a React.memo childcamelCase functions returning JSX are NOT React components. They break reconciliation, hooks, and dev tools.
renderThing() pattern — use <Thing /> component syntaxNew arrays, objects, and functions created inline in JSX props break React.memo on children.
useMemouseCallback (only when passed to memoized children)null are unnecessary — call the hook directlyuseApiQuery/useApiMutation core hooksstyle={} objectssm:, md:, lg:) for responsive designcomponents/ui/ over recreating common elementsreact-error-boundary package for function component-friendly APIresetKeys={[location.pathname]} so boundaries reset on navigationresetErrorBoundary in fallback UIkey when lists can be reordered, filtered, or modifiedMath.random() or other unstable values as keys — causes full unmount/remountkey on <React.Fragment key={id}>, not on a child{count && <Component />} when count can be 0 — renders literal 0{count > 0 && <Component />} or ternary insteadaria-label to icon-only buttons — without it, they're invisible to screen readersaria-describedby and aria-invalidaria-live="polite" for dynamic content updates (search results, notifications, toasts)React.lazy() + <Suspense> for route-level code splittingmanualChunks to split vendor bundles for better cachinglazy(() => import('./X')) — dynamic paths break build analysisuseEffect cleanup using AbortControllerbaseURL, default headers, and interceptorsref as a regular prop instead of using forwardRef (React 19+)memo/useMemo/useCallback unless measuredutils/ or components/ui/What SKILL.md sets; muted values are Claude Code's defaults
Other plugins' skills for the same job
npx claudepluginhub vadimpoltoratskiy/dev-digest-ai-marketplace --plugin engineering-paved-path14 skills in this plugin
/dependency-checkerAudits all dependencies across the repo's 6 independent packages (server, client, reviewer-core, e2e, evals, mcp-server) — no shared workspace. Distinguishes external npm dependencies from internal cross-package dependencies (tsconfig path aliases, not workspace:*), draws a Mermaid schematic of dependency relationships, breaks down installed size per package, and prioritizes findings into P0/P1/P2/Info tiers with concrete, file-specific recommendations. Read-only: reports and advises, never runs pnpm remove/update itself. Invoke explicitly: /dependency-checker, 'check our dependencies', 'audit deps', 'why is node_modules so big', 'draw the dependency graph'./drizzle-orm-patternsProvides comprehensive Drizzle ORM patterns for schema definition, CRUD operations, relations, queries, transactions, and migrations. Proactively use for any Drizzle ORM development including defining database schemas, writing type-safe queries, implementing relations, managing transactions, and setting up migrations with Drizzle Kit. Supports PostgreSQL, MySQL, SQLite, MSSQL, and CockroachDB./fastify-best-practicesGuides development of Fastify Node.js backend servers and REST APIs using TypeScript or JavaScript. Use when building, configuring, or debugging a Fastify application — including defining routes, implementing plugins, setting up JSON Schema validation, handling errors, optimising performance, managing authentication, configuring CORS and security headers, integrating databases, working with WebSockets, and deploying to production. Covers the full Fastify request lifecycle (hooks, serialization, logging with Pino) and TypeScript integration via strip types. Trigger terms: Fastify, Node.js server, REST API, API routes, backend framework, fastify.config, server.ts, app.ts./mermaid-diagramCreate Mermaid diagrams in markdown. Use when the user wants to visualize workflows, architectures, API flows, data models, state machines, or system designs. Covers flowcharts, sequence diagrams, class diagrams, ER diagrams, state diagrams, and more./next-best-practicesNext.js best practices - file conventions, RSC boundaries, data patterns, async APIs, metadata, error handling, route handlers, image/font optimization, bundling/onion-architectureAnswers 'what goes where' in the server — the layer and placement decision tree for every new file in the Fastify backend. Use when adding a new feature module, a route handler, a service method, a repository query, a new adapter, or a platform utility. Use when reviewing a PR for layer violations (routes querying the DB directly, services importing adapters without DI). Covers the annotated server directory map, the four-layer onion model (routes → service → repository → platform/adapters), module file anatomy, DI container usage patterns, module registration steps, import boundary rules, and anti-patterns. Trigger terms: where to put, new module, add route, service method, repository query, adapter, DI container, module registration, layer violation, backend architecture, server structure, which layer.15 plugins ship this exact skill · first indexed Jul 20, 2026
Showing 6 of 15 plugins, one per repository first