agentsclimarketplace

React doctor

Skill arthjean/skills/skills/react-doctor

React codebase health scanner that checks for security, performance, correctness, and architecture issues. Runs react-doctor CLI, interprets results, and provides actionable fix guidance. Use when the user says 'react-doctor', 'check my React code', 'React health check', 'scan React for issues', 'React audit', or after making React changes to catch issues early. Also triggers on: 'fix React performance', 'React best practices check', 'React code quality'. Do NOT trigger for non-React code, general JavaScript questions, or backend-only changes.From its SKILL.md

Install
npx -y skills add arthjean/skills --skill react-doctor

Assembled from the repository path, not quoted from the project. Check it against their README if it does not work.

2 things to look at

  • no licenseNo license file was found in the repository. Code published without one is not open source by default, so using it at work is a question for whoever answers licensing questions where you are.
  • 3 stars3 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.

SKILL.md

6.5 KB, ~1.4k tokens by cl100k_base, as published. Nobody here has run it

react-doctor — React Codebase Health Scanner

Scan target: $ARGUMENTS

Overview

react-doctor is a 3-step pipeline that scans React codebases for issues, interprets the results, and provides actionable fix guidance.

  1. Scan — run react-doctor CLI on the target
  2. Interpret — parse the score and diagnostics, categorize findings
  3. Guide — provide specific fix guidance for each finding, re-run to verify

Execution Flow

$ARGUMENTS -> [file-or-folder?]
     |
     v
+---------------+
|  Step 1:      |
|  SCAN         |  <- Run react-doctor CLI
+-------+-------+
        |
        v
+-------+-------+
|  Step 2:      |
|  INTERPRET    |  <- Parse score, categorize findings
+-------+-------+
        |
        v
+-------+-------+
|  Step 3:      |
|  GUIDE        |  <- Actionable fixes, re-run to verify
+-------+-------+

Runtime Output Format

Before each step, print a progress header:

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
[Step N/3] STEP_NAME
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

Step-by-Step Execution

Step 1 — Scan

Print: [Step 1/3] SCAN

1a. Determine target:

  • If $ARGUMENTS contains a path → use that as the scan target
  • If $ARGUMENTS is empty → scan the current directory (.)

1b. Run react-doctor:

bunx -y react-doctor@latest {target} --verbose --diff
  • --verbose provides detailed diagnostics per category
  • --diff scopes to recently changed files (reduces noise, faster)

If the scan fails (missing dependencies, not a React project), inform the user and suggest checking the project setup.

Step 2 — Interpret

Print: [Step 2/3] INTERPRET

2a. Parse the output:

Extract from the react-doctor output:

  • Overall score (0-100)
  • Category scores (security, performance, correctness, architecture)
  • Individual findings with file:line references and severity

2b. Categorize findings by priority:

PriorityCriteriaAction
CRITICALSecurity vulnerabilities, XSS vectors, unsafe patternsFix immediately
HIGHPerformance issues, memory leaks, missing error boundariesFix before merge
MEDIUMArchitecture concerns, missing memoization, prop drillingFix recommended
LOWBest practice suggestions, minor optimizationsFix when convenient

2c. Display results:

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
REACT DOCTOR RESULTS
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

**Score:** {N}/100
**Security:** {N}/100 | **Performance:** {N}/100
**Correctness:** {N}/100 | **Architecture:** {N}/100

**Findings:** {N} total — {N} CRITICAL | {N} HIGH | {N} MEDIUM | {N} LOW

Step 3 — Guide

Print: [Step 3/3] GUIDE

3a. For each finding (CRITICAL and HIGH first):

  • Explain WHY it's a problem (not just what react-doctor flagged)
  • Show the specific code that triggered the finding (read the file)
  • Provide a concrete fix with before/after code

3b. After fixes are applied, re-run to verify:

bunx -y react-doctor@latest {target} --verbose --diff

Compare the new score to the original. Report improvement.

3c. Summary:

━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━
SUMMARY
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━

**Score:** {before}/100 → {after}/100 ({+/-delta})
**Fixed:** {N} findings
**Remaining:** {N} findings (with justification)

Hard Rules

  1. ALWAYS run react-doctor before providing any guidance — never diagnose from memory.
  2. Read the flagged files before suggesting fixes — understand the context.
  3. Re-run after fixes to verify improvement — never claim a fix without verification.
  4. Do NOT modify files during interpretation (Step 2) — only in Step 3.
  5. Every finding must include file:line and a specific code fix.
  6. If react-doctor is not available or fails, fall back to manual inspection using Read/Grep.

DO NOT

  • Skip the scan and provide generic React advice.
  • Suggest fixes without reading the actual flagged code.
  • Ignore CRITICAL findings to focus on score improvement.
  • Run react-doctor without --verbose (insufficient detail for diagnosis).
  • Modify unrelated code while fixing flagged issues.

Done When

  • react-doctor scan executed with --verbose --diff flags
  • Results parsed and categorized by priority (CRITICAL/HIGH/MEDIUM/LOW)
  • CRITICAL and HIGH findings investigated with file:line context
  • Fixes applied for CRITICAL and HIGH findings with before/after code
  • Re-scan executed to verify improvement
  • Summary displayed with before/after score comparison

Constraints (Three-Tier)

ALWAYS

  • Run react-doctor before providing any guidance — never diagnose from memory
  • Read flagged files before suggesting fixes — understand the context
  • Re-run after fixes to verify improvement
  • Include file:line and specific code fix for every finding

ASK FIRST

  • Nothing — this is a diagnostic and fix workflow

NEVER

  • Skip the scan and provide generic React advice
  • Suggest fixes without reading the actual flagged code
  • Ignore CRITICAL findings to focus on score improvement
  • Modify unrelated code while fixing flagged issues

References

What ships with it

Read from the repository

Just SKILL.md. No reference files, no scripts.

Keep looking

Skills are one crate of 326,782. Ordering is by how many stacks a row turns up in, so the top of any crate is what has actually been picked rather than what has the most stars.