review
The review slash command analyzes code for quality issues across bugs, security, performance, and readability. It examines either specified files or current git diff changes, then delivers structured feedback organized by severity levels (critical, warnings, suggestions) with specific locations and explanations. Use this command when seeking comprehensive code quality assessment before committing changes or during pull request preparation.
mkdir -p ~/.claude/commands && curl -fsSL https://raw.githubusercontent.com/huangjia2019/claude-code-engineering/HEAD/05-Commands/projects/01-basic-commands/.claude/commands/review.md -o ~/.claude/commands/review.mdreview.md
Review code and provide feedback. Target: $ARGUMENTS (or current git diff if not specified) ## Review Focus Areas 1. **Bugs & Errors**: Logic errors, null checks, edge cases 2. **Security**: Input validation, injection risks, sensitive data 3. **Performance**: Obvious inefficiencies, N+1 queries 4. **Readability**: Naming, complexity, documentation needs ## Steps 1. If file path provided, read that file 2. If no path, run `git diff` to see current changes 3. Analyze the code against the focus areas 4. Provide structured feedback ## Output Format ```markdown ## Code Review ### Summary [One sentence overall assessment] ### Issues Found #### Critical (Must Fix) - [issue]: [location] - [brief explanation] #### Warnings (Should Fix) - [issue]: [location] - [brief explanation] #### Suggestions (Nice to Have) - [suggestion]: [location] - [brief explanation] ### What's Good - [positive observation] ``` ## Guidelines - Be specific about locations (file:line if possible) - Provide actionable feedback - Don't nitpick style unless it impacts readability - Acknowledge good patterns you see
Deep analysis of code against project standards
API design patterns and conventions for this project. Covers RESTful URL naming, response format standards, error handling, and authentication requirements. Use when writing or reviewing API endpoints, designing new APIs, or making decisions about request/response formats.
Generate comprehensive API documentation by scanning Express route files.
Generate API documentation from code. Use when the user wants to document APIs, create API reference, generate endpoint documentation, or needs help with OpenAPI/Swagger specs.
Explore and analyze API-related code. Use when investigating endpoints, routing, or HTTP handling.
Generate API endpoint documentation from Express route files. Use when the user asks to generate, update, or review API docs for Express.js routes.
Explore and analyze authentication-related code. Use when investigating auth flows, session management, or security.
Analyze root cause of bugs after location is identified. Second step in bug investigation.