add-language-rules
Workflow command scaffold for add-language-rules in everything-claude-code.
Comprehensive React/JSX code review for hook correctness, render performance, server/client component boundaries, accessibility, and React-specific security. Invokes the react-reviewer agent (and typescript-reviewer alongside on TSX/JSX changes).
> /plugin marketplace add affaan-m/ECC > /plugin install ecc@ecc
How it fires
How this command gets triggered: by you, by Claude, or both.
/react-reviewContext preview
What this command does when you run it.
Comprehensive React/JSX code review for hook correctness, render performance, server/client component boundaries, accessibility, and React-specific security. Invokes the react-reviewer agent (and typescript-reviewer alongside on TSX/JSX changes).
description: Comprehensive React/JSX code review for hook correctness, render performance, server/client component boundaries, accessibility, and React-specific security. Invokes the react-reviewer agent (and typescript-reviewer alongside on TSX/JSX changes).
This command invokes the **react-reviewer** agent for React-specific code review. For pull requests touching `.tsx`/`.jsx` files, both `react-reviewer` and `typescript-reviewer` should run — each owns a distinct lane.
1. **Identify React Changes**: Find modified `.tsx`/`.jsx` files (and React-containing `.ts`/`.js` files) via `git diff` 2. **Run Lint**: Execute `eslint` with `eslint-plugin-react-hooks` and `eslint-plugin-jsx-a11y` 3. **Typecheck**: Run `tsc --noEmit` or the project's canonical typecheck command 4. **Review React Lanes Only**: Hook rules, RSC boundaries, accessibility, render performance, React-specific security 5. **Generate Report**: Categorize issues by severity (CRITICAL / HIGH / MEDIUM)
Use `/react-review` when:
For pure `.ts`/`.js` changes with no React imports, use `/code-review` (general) or invoke `typescript-reviewer` directly.
| Tool | Scope | |---|---| | `react-reviewer` (this command) | Hooks rules, JSX, RSC, a11y, React-specific security, render perf | | `typescript-reviewer` | Generic TS/JS — `any` abuse, async correctness, Node security | | `security-reviewer` | Project-wide security audit | | `/code-review` | Generic uncommitted-changes or PR review |
On a TSX/JSX PR, invoke both `react-reviewer` and `typescript-reviewer`. Findings from each are non-overlapping by design.
# Lint (required for any meaningful review)
npx eslint . --ext .tsx,.jsx,.ts,.js
# Typecheck (skip cleanly for JS-only projects)
npm run typecheck --if-present
[ -f tsconfig.json ] && tsc --noEmit -p tsconfig.json
# Targeted a11y rules
npx eslint . --rule 'jsx-a11y/alt-text: error' \
--rule 'jsx-a11y/anchor-is-valid: error' \
--rule 'jsx-a11y/click-events-have-key-events: error'
# Supply-chain
npm auditIf `eslint-plugin-react-hooks` or `eslint-plugin-jsx-a11y` is not configured, the review will flag the gap as a HIGH config issue and continue.
User: /react-review
Agent:
# React Code Review Report
## Files Reviewed
- src/components/UserCard.tsx (modified)
- src/hooks/useUser.ts (new)
## Lint Results
PASS: eslint clean
PASS: typecheck clean
## Issues Found
[CRITICAL] Unsanitized dangerouslySetInnerHTML
File: src/components/UserCard.tsx:42
Issue: User-controlled bio rendered as raw HTML.
Why: XSS via stored script tags in user input.
Fix: Sanitize with DOMPurify or render as text:
```tsx
import DOMPurify from "isomorphic-dompurify";
<div dangerouslySetInnerHTML={{ __html: DOMPurify.sanitize(user.bio) }} />[HIGH] Effect cleanup missing File: src/hooks/useUser.ts:18 Issue: `fetch` call without AbortController; setState on unmounted component possible. Fix: Add AbortController and cleanup:
useEffect(() => {
const ac = new AbortController();
fetch(`/api/users/${id}`, { signal: ac.signal })
.then(r => r.json())
.then(setUser);
return () => ac.abort();
}, [id]);Recommendation: FAIL: Block merge until CRITICAL issue is fixed
## Approval Criteria | Status | Condition | |---|---| | PASS: Approve | No CRITICAL or HIGH issues | | WARNING: Warning | Only MEDIUM issues (merge with caution) | | FAIL: Block | CRITICAL or HIGH issues found | ## Integration with Other Commands - Run `/react-build` first if the build is broken - Run `/react-test` to ensure component tests pass - Run `/react-review` before merging - Use `/code-review` for non-React-specific concerns on the same PR ## Related - Agent: `agents/react-reviewer.md` - Companion agent: `agents/typescript-reviewer.md` (run alongside for TSX/JSX PRs) - Skills: `skills/react-patterns/`, `skills/react-testing/`, `skills/accessibility/` - Rules: `rules/react/`
Your agent can write code, but ECC gives it a coordinated engineering system and toolbox: it plans before it builds, verifies changes with tests, reviews its own work from a fresh context, remembers what matters, and turns repeated wins into reusable skills
Repo: affaan-m/ECC
Workflow command scaffold for add-language-rules in everything-claude-code.
Workflow command scaffold for database-migration in everything-claude-code.
Workflow command scaffold for feature-development in everything-claude-code.
Answer a quick side question without interrupting or losing context from the current task. Resume work automatically after answering.
Pull the latest ECC repo changes and reinstall the current managed targets.