Repository navigation
feat(assets): update react-compiler-migration and make it team-agnostic - #255
Open
Prithpal-Sooriya wants to merge 5 commits into
Open
Prithpal-Sooriya wants to merge 5 commits into
Prithpal-Sooriya wants to merge 5 commits into
Conversation
Make the skill team-agnostic, label metamask-mobile specifics as repo notes, add a section on the lint:react-compiler burndown baseline, and add validated recipes for exhaustive-deps suppressions, render-time refs and failRequest narrowing.
Prithpal-Sooriya
force-pushed
the
fm/rc-skill-stable
branch
from
November 17, 2026 19:05
411ec8a to
56f2294
Compare
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🤖 Update
assets/react-compiler-migrationand make it usable by any team. It staysmaturity: experimentalfor now; promotion to stable can come after other teams have used it.Description
experimental, so it still installs only on opt-in. Adds the recommended## When To Usesection, which clears itsyarn audit:skillswarning.Repo notes: metamask-mobilesection: Jest gating viascripts/react-compiler.js, the offline.npmrc,react-hookslint,ONLY_INCLUDE_IFfences andyarn lint:tsc. The rest of the text refers to them conditionally. Both marker commands are pinned toreact-compiler-marker@0.2.0.yarn lint:react-compilerfails": a new failing file or a higher count fails the check. An improved file must leave the baseline viayarn lint:react-compiler --update. Never grow the baseline. If the repo has no such script, the marker run is the check.references/patterns.md:exhaustive-depssuppressions:useEffectEventfor deps that must stay out; inlining a render-body helper into the effect; a run-once ref guard when a mount-only[]effect gets honest deps (missing guard → Jest OOM loop), guarding on the tracked dep.usePreviousfor "previous render" refs; a state-held previous key instead of a ref for reset-on-prop-change; don't moveuseAnimatedValueinto an effect.failRequestmust be afunctiondeclaration. Aneverarrow assigned to an unannotatedconstdoes not narrow (TS2345; reproduced undertsc --strict)..set()/.get()evidence (JesttoHaveAnimatedStyle, 3.16+).use...and reuse the existing props type.finally/throw, but value blocks surface next run.New recipes were checked with
react-compiler-marker@0.2.0andbabel-plugin-react-compiler@1.0.0on minimal reproductions. The state-held previous key compiles; the ref version still failsCannot access refs during render. A probe-by-throwrecipe from the source notes was dropped because 0.2.0 has no--log-leveland the probe gave no signal.Testing
yarn lint✅,yarn test77/77 ✅,yarn audit:skills0 errors (react-compiler-migration has no warnings).Adversarial review (adverse)
Final verdict (round 2/3, run while the PR still promoted the skill to stable): SHIP-WITH-CAVEATS (3/3 ship, 0/3 block)
Findings: 0 critical · 6 warning · 6 info. Fixed: unpinned
npx @latest(pinned 0.2.0); falseuseCallbackre-run claim; Jest-gating mechanism duplicated outside Repo notes. Round 1 also fixed: one-pass-vs-first-failure contradiction; new recipes missing verification lines; repo facts stated unconditionally; shared-value.set()during render (now kept in an effect);useEffectEventpassed as a value (now called); broken sentence; unverifiable probe recipe (removed).Declined:
Reviewer: Pi Opus 5.5 (litellm/claude-opus-5-5) via adverse (3 personas, 2 rounds).
Type of Change
Checklist