Agent skill
frontend-code-review
Trigger when the user requests a review of frontend files (e.g., `.tsx`, `.ts`, `.js`). Support both pending-change reviews and focused file reviews.
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/frontend-code-review-yairbederman-engineeringagency
SKILL.md
Frontend Code Review
Intent
Use this skill whenever the user asks to review frontend code (especially .tsx, .ts, or .js files). Support two review modes:
- Pending-change review – inspect staged/working-tree files slated for commit and flag checklist violations before submission.
- File-targeted review – review the specific file(s) the user names and report the relevant checklist findings.
Checklist Categories
Code Quality
- Component follows single responsibility principle
- Props have proper TypeScript typing
- No unused imports or variables
- Consistent naming conventions
- Error boundaries in place where needed
- Proper use of React hooks (dependencies, cleanup)
- No direct DOM manipulation
- Accessibility attributes present (aria-*, role)
Performance
- Expensive computations memoized (useMemo, useCallback)
- Large lists use virtualization
- Images optimized and lazy-loaded
- No unnecessary re-renders (React.memo where appropriate)
- Bundle size considered (dynamic imports for large deps)
- No N+1 query patterns in data fetching
Business Logic
- Edge cases handled (empty states, loading, errors)
- User input validated
- Security considerations addressed (XSS, injection)
- Proper error messages displayed to user
- Business rules correctly implemented
Review Process
- Open the relevant component/module
- Gather lines that relate to:
- Class names and styling
- React hooks and state
- Prop memoization
- Event handlers
- For each checklist item, note where the code deviates
- Capture representative code snippets
- Compose the review per the template below
Required Output
Template A (any findings)
# Code Review
Found <N> urgent issues need to be fixed:
## 1. <brief description of bug>
**FilePath:** `<path>` line `<line>`
```<language>
<relevant code snippet>
Suggested Fix
... (repeat for each urgent issue) ...
Found <M> suggestions for improvement:
1.
FilePath: <path> line <line>
<relevant code snippet>
Suggested Fix
... (repeat for each suggestion) ...
If there are no urgent issues, omit that section.
If there are no suggestions, omit that section.
If issue count exceeds 10, summarize as "10+ urgent issues" and output only the first 10.
**Follow-up:** If at least one issue requires code changes, ask:
> "Would you like me to apply the suggested fixes?"
### Template B (no issues)
Code Review
No issues found.
## Severity Guidelines
| Severity | Description | Example |
|----------|-------------|---------|
| 🔴 Urgent | Blocks release, security/data issue | XSS vulnerability, data leak |
| 🟠 Important | Should fix before merge | Missing error handling |
| 🟡 Suggestion | Code quality improvement | Naming convention, memoization |
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?