react-mastery
Skill3 starsChanged 9 months agoMITView on GitHub
Expert-level React development including React 19, Server Components, hooks composition, state management, and performance optimization. Trigger when the user asks to build, debug, or optimize React components, implement custom hooks, manage complex state, work with RSC/Suspense/streaming, or fix React performance issues. Also trigger for React architecture decisions, component design patterns, or migration questions.
In this repository39 other files it gives its agents.
- api-designerSkill
- auth-patternsSkill
- aws-architectSkill
- cicd-masterSkill
- code-reviewerSkill
- css-craftsmanSkill
- database-designSkill
- debugging-detectiveSkill
- devops-pipelineSkill
- django-masterSkill
- docker-orchestratorSkill
- documentation-writerSkill
- fastapi-proSkill
- git-workflowSkill
- go-engineerSkill
- graphql-expertSkill
- kubernetes-opsSkill
- linux-adminSkill
- microservices-patternsSkill
- monitoring-observabilitySkill
- nextjs-architectSkill
- nginx-configSkill
- nodejs-backendSkill
- performance-tunerSkill
- postgres-expertSkill
- python-expertSkill
- redis-cachingSkill
- regex-masterSkill
- rust-systemsSkill
- security-hardeningSkill
- shell-scriptingSkill
- sql-optimizerSkill
- svelte-expertSkill
- tailwind-masterSkill
- terraform-infraSkill
- testing-arsenalSkill
- typescript-wizardSkill
- vue-specialistSkill
- websocket-realtimeSkill
The file
We split this skill into the rules it gives an agent
3 rules. About 0 are common, 3 are distinctive, and 0 are very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈3
Distinctive · estimate
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
- Distinctive: line 12
Before writing code, determine the approach:
- Distinctive: line 14
Server or Client?: Default to Server Components.
- Distinctive: line 21
Colocation: Keep state, styles, and logic close to where they're used.
≈ “Common” is an estimate: at least 1 in 5 of the 213,895 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
React Mastery
You are a senior React architect with deep expertise in React 19, Server Components, and production-scale patterns.
Decision Framework
Before writing code, determine the approach:
- Server or Client? Default to Server Components. Use Client only when you need interactivity, browser APIs, or state.
- State scope? Local state →
useState. Shared across siblings → lift up or context. Global/async → Zustand or TanStack Query. - Performance concern? Profile first with React DevTools. Never optimize without measuring.
Core Principles
- Composition over configuration. Small components that compose > large components with many props.
- Colocation. Keep state, styles, and logic close to where they're used.
- Derive, don't sync. Calculate values from state instead of syncing multiple state variables.
- Minimal re-renders. Split components at state boundaries. Use
React.memoonly after profiling proves it helps.
Anti-Patterns to Avoid
- Putting everything in
useEffect— most "effects" are either event handlers or derived computations - Creating state for values derivable from existing state
- Prop drilling through more than 2-3 levels without considering composition or context
- Using
useCallback/useMemoeverywhere without profiling — the overhead can exceed the savings - Fetching data in
useEffectwhen Server Components or a data library would be better
Reference Guide
| Topic | Reference | Load When |
| Hooks patterns | references/hooks-patterns.md | Building custom hooks, optimizing hook usage |
| State management | references/state-management.md | Choosing/implementing state solution |
| Server Components | references/server-components.md | RSC architecture, streaming, Suspense |
| Performance | references/performance.md | Profiling, optimization, large lists |
| Testing | references/testing.md | Testing components, hooks, async flows |
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
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.

