/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
npx claudepluginhub yamchinsky/dev-digest-ai-marketplace --plugin engineering-paved-path12 skills in this plugin
/frontend-architectureFolder structure and code organization for React + Next.js (App Router) projects. Use this skill whenever the user asks where files should live (components, hooks, utils, helpers, lib, services, constants, types), how to break a component into smaller pieces, how to organize a feature folder, where to put business logic, when to use a barrel index, or how to lay out app/ in Next.js (route groups, private folders). Trigger on phrases like 'folder structure', 'project structure', 'where should I put', 'how to organize', 'where do constants go', 'utils vs helpers', 'app router structure'. Covers organization decisions only — NOT React hook rules or render patterns (use engineering-paved-path:react-best-practices) and NOT Next-specific runtime behavior (use engineering-paved-path:next-best-practices)./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./nestjs-best-practicesNestJS application patterns for TypeScript backends — modules and providers, dependency injection and injection tokens, the composition root, thin controllers, guards/interceptors/pipes/filters and their execution order, validation at the edge, ConfigModule and typed configuration, lifecycle hooks, exception filters, and testing with Test.createTestingModule. Use when building, wiring, reviewing or debugging a NestJS application: adding a module or a provider, resolving 'Nest can't resolve dependencies of X', choosing an injection scope, registering a global guard, shaping an error response, writing a testing module, or upgrading a NestJS major. Trigger terms: NestJS, Nest, @nestjs/common, @nestjs/core, app.module.ts, @Module, @Injectable, @Controller, provider, injection token, forwardRef, ValidationPipe, exception filter, APP_GUARD, Test.createTestingModule, nest build, nest start. NestJS runtime and wiring ONLY — NOT which layer a file belongs to (use engineering-paved-path:onion-architecture), NOT TypeORM query, migration or entity mechanics (use engineering-paved-path:typeorm-patterns), NOT PostgreSQL schema design (use engineering-paved-path:postgresql-table-design), NOT Zod schema mechanics (use engineering-paved-path:zod).15 plugins ship this exact skill · first indexed Jul 20, 2026
Showing 6 of 15 plugins, one per repository first
Other plugins' skills for the same job