Claude
Skills
Sign in
โ† Back

code-review

Included with Lifetime
$97 forever

# Code Review

Code Review

What this skill does

# Code Review

Provide constructive, actionable feedback on security, correctness, performance, and maintainability.

## Review Dimensions

| Dimension | Key Checks |
|-----------|------------|
| **Security** | Injection (SQL, XSS, command), auth gaps, data exposure, CORS, SSRF |
| **Correctness** | Logic errors, edge cases, race conditions, off-by-one |
| **Performance** | O(nยฒ) loops, N+1 queries, memory leaks, missing indexes |
| **Readability** | Naming, nesting depth, magic numbers, DRY |
| **Error Handling** | Silent swallowing, missing cleanup, unhelpful messages |
| **Testability** | Tight coupling, hidden dependencies, side effects |

## Severity Levels

| Level | Criteria | Action |
|-------|----------|--------|
| ๐Ÿ”ด CRITICAL | Security vulns, data loss, crashes | Block merge |
| ๐ŸŸ  HIGH | Bugs, performance issues | Fix before merge |
| ๐ŸŸก MEDIUM | Code smells, refactoring | Fix soon |
| ๐ŸŸข LOW | Style, alternatives | Optional |

## Output Format

```markdown
## Summary
[2-3 sentences: quality, strengths, concerns]

## ๐Ÿ”ด Critical Issues
**Location:** file.js:42
**Issue:** SQL injection
**Impact:** Data breach
**Fix:** Use parameterized query
\`\`\`js
// Before
db.query(`SELECT * FROM users WHERE id = ${id}`)
// After
db.query('SELECT * FROM users WHERE id = ?', [id])
\`\`\`

## ๐ŸŸ  High Priority
[Same format]

## ๐ŸŸก/๐ŸŸข Other
[Same format]

## โœ… Positive
[Good patterns observed]
```

## Principles

- Specific locations, not vague criticism
- Explain impact, not just what's wrong
- Code examples for fixes
- Balance criticism with recognition

Related in Code Review