Loop 067

The React Doctor 100/100 loop

An AI coding-agent workflow for inventorying every production React app, fixing React Doctor findings without suppression, and proving a genuine 100/100 result with full project checks.

Ready-to-use prompt

Copy the loop

Bring every production React app in [repository] to a freshly verified React Doctor score of 100/100. Inventory app roots, record a full `npx react-doctor@latest --verbose` baseline, fix one root cause at a time, and rerun the full scan plus relevant typecheck, lint, tests, and builds. Never hide findings with exclusions, ignores, suppressions, deleted behavior, or relaxed rules. Stop at 100/100 for every app, blocked, approval-required, or no measurable progress; preserve unrelated work and report exact proof.

Verify / stop

Every production React app has a genuine fresh 100/100 result.

Record the React Doctor version, app roots, full final scan, and repository validation results; distinguish pre-existing failures and blockers from regressions caused by the repair work.

Context and guidanceWhen to use it, steps, safety notes, and related loops
Published
Updated

Use this when

Use this for an authorized repository-wide React health pass when every production React app can be identified and a complete scan plus project checks can run locally.

How to run it

  1. Inventory the repository, production React app roots, current worktree state, and available validation commands.
  2. Run and record a full React Doctor baseline for every production app.
  3. Group findings by root cause and repair one coherent cause without weakening rules or changing unrelated behavior.
  4. Rerun the full scan and relevant typecheck, lint, tests, and builds, keeping only verified improvements.
  5. Escalate from symptom patches to ownership or data-flow analysis when a finding survives repeated repairs.
  6. Stop only at the success, blocked, approval-required, or no-progress state and return exact evidence.

Why it works

A complete app inventory and fresh full scans prevent local or diff-only checks from masquerading as repository-wide health. Root-cause repair and anti-suppression rules make the final score evidence of better code rather than a configured-away problem.

Implementation note

Do not reset or overwrite unrelated work, disable findings, exclude files, relax severity, add unsafe casts or ignore directives, or delete meaningful behavior. Ask before breaking dependency upgrades or architectural changes outside the stated scope.

Contributor playbookBoundaries, required outputs, implementation guidance, and reviewer handoff

Do not use this when

  • Do not use this exhaustive loop for a single known finding when a bounded repair pass is sufficient.
  • Do not run it when the repository or production app roots are unavailable.

Required outputs

  • Initial and final scores for every production React app with the exact scan version and commands.
  • Resolved findings, retained fixes, changed files, validation results, blockers, and remaining risks.

Match the method to the artifact

  • Prioritize security and correctness before performance, effects and state, accessibility, and maintainability.
  • For Next.js, preserve Server and Client boundaries, routing, caching, revalidation, and hydration behavior.
  • Review effects for cleanup, cancellation, stale closures, dependency accuracy, and race conditions.
  • Preserve semantic HTML, labels, keyboard behavior, focus behavior, APIs, routes, auth, and data contracts.

Reviewer handoff

  • Reject a claimed 100/100 result that relies on a partial scan, diff-only scan, suppression, exclusion, or unrecorded tool version.
  • Separate documented pre-existing validation failures from regressions caused by the loop.