react-doctor
Installation
SKILL.md
React Doctor — React Performance & Health Audit
Mandatory Pre-Flight Context Inspection
Before auditing React components for performance or health issues, you MUST inspect:
- Re-render triggers (Section 24) → Identify inline object/array props and inline callback handlers breaking memoization
useEffectCleanup (Section 31) → Ensure all event listeners, intervals, and subscriptions return explicit cleanup functions- Derived State Anti-Pattern (Section 41) → Ban props duplicated into state (
useState(props.val)); derive values directly during render
Diagnose and resolve unnecessary re-renders, state synchronization bugs, memory leaks, and hook dependency issues in React applications.
Activation Boundaries
- Activate when: Operating in tasks requiring Scan React and Next.js applications for security, performance, re-render inefficiencies, memory leaks, and correctness issues..
- DO NOT activate when: The task falls strictly outside react-doctor domain or belongs to a different dedicated specialist.