agentleFS
ku5icku5ic/claude-kit/skills/react-patterns/SKILL.md

react-patterns

Skill2 starsChanged 8 days agoMITView on GitHub

React core patterns for hooks rules, component design, rendering performance, anti-patterns, and review checklist, independent of any meta-framework. Use whenever the project contains `.jsx`/`.tsx` files or `react` in `package.json`, OR the user asks about React, its hooks, component structure, or rendering and hydration behavior, even if React is not mentioned by name.

38 other projects use a version of this.

Adopted by

Most recently taken up by

Used with

Projects with it also use typescript-strict, docker-expert and 8 more.

Other files people use alongside this one.

Files found in the same public projects as a version of this one, more often than they turn up anywhere else. Each project counts once, large collections count for less, and this file's own repository is left out.
  • MicrosoftSkill

    typescript-strict

    Enable TypeScript strict mode (strict, noImplicitAny, strictNullChecks, etc.) in a project and fix the resulting errors without weakening types, tests, or runtime behavior. Use when asked to "enable strict mode", "turn on TypeScript strict", "fix strict errors", or migrate a codebase to strict type checking.

    Also in 3 projects that use this

  • xfstudioSkill

    docker-expert

    Docker containerization expert with deep knowledge of multi-stage builds, image optimization, container security, Docker Compose orchestration, and production deployment patterns. Use PROACTIVELY for Dockerfile optimization, container issues, image size problems, security hardening, networking, and orchestration challenges.

    Also in 3 projects that use this

  • BlockSkill

    testing-strategy

    Guidelines for writing effective tests in this project

    Also in 4 projects that use this

  • LangChainSkill

    database-migrations

    Database migration patterns and schema versioning

    Also in 4 projects that use this

  • MicrosoftSkill

    error-handling

    统一错误处理系统。在添加 API 端点、修改错误处理、添加前端 API 调用、编写错误相关测试时使用。

    Also in 5 projects that use this

  • HABUBUSSSkill

    backend-patterns

    Backend architecture patterns, API design, database optimization, and server-side best practices for Node.js, Express, and Next.js API routes.

    Also in 5 projects that use this

  • +1 more from microsoft

The file

We split this skill into the rules it gives an agent

1 rule. 0 are common, 1 is distinctive, and 0 are very specific to this project.

  • 0

    Common

    Most of the 34 edited versions we read keep these.

  • 1

    Distinctive

    This author's own choices. Worth a look.

  • 0

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Default assumption: React 19 with the modern (concurrent) renderer.

    line 8

“Common” is measured: kept by at least 6 in 10 of the 34 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

React patterns

Default assumption: React 19 with the modern (concurrent) renderer.

  • Most rules apply unchanged to React 18; deltas (use, useActionState, useFormStatus, useOptimistic, Actions) are called out where they matter.
  • Server Components are a feature of frameworks built on React; framework-specific patterns load when those framework signals are present in the project.
  • Adapt advice to the version in the project's package.json or lockfile.

Reference files

FileCovers
reference/correctness.mdRules of Hooks, dependency arrays, key stability, effect cleanup, render pitfalls
reference/performance.mdMemoization costs, React.memo, virtualization, lazy init, context, React Compiler
reference/structure.mdControlled vs uncontrolled, derived state, prop drilling, effects vs handlers
reference/anti-patterns.mdSeven review-time anti-patterns with severity calls
reference/when-to-split.mdHeuristics for component splitting and what does not justify a split

References

Version notes

Checked: 2026-09-26 against https://react.dev/blog and Context7 /react/react

  • 19.3 (2026-09-09): patch-level; no guidance change.
  • 19.0 (2024-12-05): Actions, use, useActionState, useFormStatus, useOptimistic. Verify against the per-hook page on react.dev, not older blog posts.
  • React Compiler: stable, opt-in, installed per build tool; not present in every project.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.