review-pr
Review pull request for DesignSetGo WordPress plugin standards
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
Menu
Review pull request for DesignSetGo WordPress plugin standards
Install with Codex or Claude Copy this prompt, paste it into Codex, Claude, or another assistant, and let it review the skill page and install it for you.
Based on SOC occupation classification
Create a new Gutenberg block with scaffolding
Use when working with the WordPress Abilities API (wp_register_ability, wp_register_ability_category, /wp-json/wp-abilities/v1/*, @wordpress/abilities) including defining abilities, categories, meta, REST exposure, and permissions checks for clients.
Prepare plugin for WordPress.org deployment
Use when generating responses containing factual claims, API details, configuration specifics, version compatibility, or recalled knowledge that could be hallucinated - especially when not working directly from source code or command output
Use when executing implementation plans with independent tasks in the current session
Create a block extension to enhance core WordPress blocks
| name | review-pr |
| description | Review pull request for DesignSetGo WordPress plugin standards |
| context | fork |
| agent | Explore |
| allowed-tools | Read, Glob, Grep, Bash(git *), Bash(npm run *) |
Act as a senior WordPress plugin developer reviewing a pull request for the DesignSetGo WordPress plugin. Provide thorough, actionable feedback focused on code quality, WordPress best practices, and adherence to plugin standards.
First, fetch PR details using GitHub CLI:
# Get PR details (use PR number from user or current branch)
gh pr view [PR_NUMBER] --json title,body,files,additions,deletions,labels,author
# Get PR diff
gh pr diff [PR_NUMBER]
# Get PR checks status
gh pr checks [PR_NUMBER]
For each changed file in the PR:
Review against .claude/CLAUDE.md standards:
dsgo- (CSS), dsgoAttributeName (JS), designsetgo_ (PHP)useBlockProps() and useInnerBlocksProps()ColorGradientSettingsDropdown in <InspectorControls group="color"> with clientId prop__next40pxDefaultSize and __nextHasNoMarginBottom on form componentssupports in block.json before custom controlssrc/styles/style.scss AND src/styles/editor.scssuseInnerBlocksProps() instead of plain <InnerBlocks />:where() for low specificity)window.open(url, '_blank'); win.opener = null!important unless for accessibility/user expectation/WP core overrideaddFilter() with explicit block name allowlistgrep -r "ComponentName" src/ to find all usagesnpm run build and checked console (editor + frontend)[data-dsgo-*] selectors with event delegationblock.json for registration (not JavaScript-only)supports configuration for FSEexample property for pattern previewstextdomain: "designsetgo"__() or _x())useBlockProps() in edit functionsuseBlockProps.save() in save functionsesc_html(), esc_attr(), esc_url()build/ not src/__(), _e(), _n(), _x()@wordpress/i18nVerify the PR author has tested:
npm run buildnpm run lint:js, npm run lint:css, npm run lint:phpCheck commit messages follow format:
type: descriptionfeat, fix, refactor, style, docs, chorefeat(tabs): add keyboard navigation supportfix(stack): correct spacing calculationrefactor: simplify color control logicdocs: update container width documentationGenerate review feedback in this structure:
# Pull Request Review: [PR Title]
**PR #:** [NUMBER]
**Author:** [@username]
**Branch:** `[branch-name]` โ `[target-branch]`
**Status:** [Approve โ
| Request Changes โ | Comment ๐ฌ]
## Summary
[Brief overview of what this PR does and your overall assessment]
**Changed Files:** [X] files, [+XXX -XXX] lines
## โ
What's Good
[Highlight 2-3 things done well]
1. [Specific positive feedback with file reference]
2. [Specific positive feedback with file reference]
## โ Issues to Address (Required)
[Only include if there are blocking issues]
### ๐ด Critical (Must Fix)
#### 1. [Issue Title]
**File:** [filename.js:123](path/to/file.js#L123)
**Problem:**
[Clear description of the issue]
**Why this matters:**
[Impact on users/functionality/security]
**Suggested fix:**
```javascript
// Current code (problematic)
[show current code]
// Suggested fix
[show fixed code]
Reference: [Link to relevant doc or standard]
[Same format as critical, but for non-blocking issues]
[Nice-to-have improvements that aren't required]
Before merging, ensure:
# Build and lint
npm run build
npm run lint:js
npm run lint:css
npm run lint:php
# Check file sizes
ls -lh build/ | grep -E "\.js$|\.css$"
# Verify styles included
grep -i "class-name" build/style-index.css
Manual testing:
[List key files reviewed with brief notes]
[Link to relevant internal docs]
For PR Author:
For Reviewer:
[Any other feedback, questions, or discussion points]
Review Status: [Approve โ | Request Changes โ | Comment ๐ฌ]
## Execution Steps
1. **Parse user request** - Get PR number or use current branch
2. **Fetch PR details** - Use gh CLI to get files, diff, metadata
3. **Read changed files** - Read full content (not just diff) of each changed file
4. **Check for shared code impact** - If shared utilities changed, grep for all usages
5. **Review against standards** - Check CLAUDE.md standards and common pitfalls
6. **Check WordPress best practices** - Security, accessibility, performance, i18n
7. **Verify testing** - Check if tests exist, build succeeds, linting passes
8. **Generate review** - Use format above with specific file references and line numbers
9. **Prioritize issues** - Critical (blocking) vs Important (should fix) vs Suggestions
## Key Principles
- **Be constructive, not critical** - Frame feedback positively
- **Be specific** - Include file names and line numbers
- **Provide solutions** - Don't just point out problems, show how to fix
- **Explain why** - Help the author understand the reasoning
- **Reference docs** - Link to relevant standards and guides
- **Acknowledge good work** - Highlight what's done well
- **Think production** - Would you be comfortable merging this?
## Important Notes
- **Read full files, not just diffs** - Context matters
- **Test shared code impact** - Use grep to find all usages
- **Check both editor and frontend** - Common pitfall
- **Verify styles in both places** - style.scss AND editor.scss
- **Look for security issues** - XSS, SQL injection, command injection
- **Check accessibility** - Keyboard nav, screen readers, contrast
- **No console.log in production** - Should be removed
- **Deprecations required** - If changing attributes or HTML structure
## Commands to Run
```bash
# Get PR info
gh pr view [NUMBER] --json title,body,files,additions,deletions
gh pr diff [NUMBER]
gh pr checks [NUMBER]
# Check for shared code usage (if utilities changed)
grep -r "ComponentName" src/
# Check style includes
grep -i "block-name" build/style-index.css
grep -i "block-name" build/editor.css
# Verify build and lint
npm run build
npm run lint:js
npm run lint:css
npm run lint:php
# Check file sizes
ls -lh build/ | grep -E "\.js$|\.css$"
A successful PR review:
Remember: The goal is to help ship high-quality code that follows plugin standards and WordPress best practices.