React Component Reviewer
Analyzes React components for performance, accessibility, and modern hook usage.
Best use case
React Component Reviewer is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
Analyzes React components for performance, accessibility, and modern hook usage.
Teams using React Component Reviewer should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/react-code-reviewer/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How React Component Reviewer Compares
| Feature / Agent | React Component Reviewer | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
Analyzes React components for performance, accessibility, and modern hook usage.
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
Related Guides
SKILL.md Source
# React Component Reviewer
## What this skill does
This skill directs the agent to review a specific React component or file against modern React best practices. It specifically checks for:
- Unnecessary re-renders (missing `useMemo`/`useCallback`)
- Accessibility violations (missing ARIA attributes, improper semantics)
- Stale closures in `useEffect` or event handlers
- Prop drilling that could be solved with Context or component composition
- Proper TypeScript typing
## How to use
### Claude Code / Antigravity
Copy this file to `.agents/skills/react-code-reviewer/SKILL.md` in your project.
Then ask the agent: *"Review `components/MyComponent.tsx` using the React Component Reviewer skill."*
### Cursor
Add this prompt to your `.cursorrules` file or save it as a custom prompt in the Cursor AI pane.
## The Prompt / Instructions for the Agent
When asked to review a React component, follow these exact steps:
1. **Analyze State & Renders:** Look for state that could be derived. Identify any expensive calculations not wrapped in `useMemo`. Look for object/function definitions inside the render body that are passed as props to memoized children.
2. **Analyze Hooks:** Ensure `useEffect` dependencies are complete and correct. Check for race conditions in asynchronous effects.
3. **Analyze Accessibility:** Verify that interactive elements use `<button>` or `<a>` with proper `href`. Ensure images have `alt` text. Check for keyboard navigability.
4. **Format Output:** Present your review in the following markdown format:
```markdown
### 🚀 Performance
- [List findings here]
### ♿ Accessibility
- [List findings here]
### 🏗️ Architecture & Best Practices
- [List findings here]
### 💡 Suggested Refactor
Provide the refactored code block here.
```
## Example
**Input to Agent:**
> "Please review the UserProfile.tsx component."
**Output from Agent:**
> ### 🚀 Performance
> - The `formatDate` function is defined inside the component and passed to a child, causing unnecessary re-renders. It should be moved outside the component or wrapped in `useCallback`.
>
> ### ♿ Accessibility
> - The "Save" div acts as a button but lacks `role="button"` and `tabIndex={0}`. It should be a `<button>` element.
>
> *(...continues with suggested refactor)*Related Skills
Responsive Layout Reviewer
Reviews HTML/CSS or component code for responsive design issues across mobile, tablet, and desktop breakpoints.
Hallucination Risk Reviewer
Reviews an AI-generated response or LLM application output for factual risks, hallucination patterns, and confidence calibration issues.
Database Schema Reviewer
Reviews database schemas for normalization issues, missing indexes, naming inconsistencies, and scalability risks.
Unit Test Writer
Generates comprehensive unit tests for any function or module with edge cases.
Unit Test Improver
Reviews existing unit tests for gaps, weak assertions, and missing edge cases, then rewrites them to be more robust.
Troubleshooting Guide Builder
Builds a structured troubleshooting guide with symptom → cause → fix format for any tool or system.
Tech Debt Auditor
Identifies and prioritizes technical debt in a codebase with an effort/impact matrix.
Technical Blog Post Writer
Writes engaging, accurate technical blog posts targeted at developer audiences.
Stack Trace Analyzer
Interprets error stack traces to pinpoint root cause, explain what went wrong, and suggest fixes.
SQL Query Optimizer
Reviews SQL queries for performance issues and rewrites them with optimized execution plans.
Sprint Summary Generator
Converts a list of completed tickets or commits into a clear sprint summary for stakeholders.
Social Post Thread Writer
Converts a blog post, idea, or document into an engaging Twitter/X or LinkedIn thread with hooks and CTAs.