-
Notifications
You must be signed in to change notification settings - Fork 5.4k
build: Enable React Compiler for Browserify builds, fix react-compiler/react-compiler ESLint rule violations
#37480
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
davidmurdoch
merged 83 commits into
main
from
jongsun/build/251103-enable-react-compiler
Nov 26, 2025
+2,475
−1,581
Merged
Changes from 82 commits
Commits
Show all changes
83 commits
Select commit
Hold shift + click to select a range
9b4cd28
Set `react-hooks/rules-of-hooks` eslint ruleset to "error"
MajorLift af51e2b
Fix `rules-of-hooks` violations
MajorLift c53e435
Rename: `{s,useS}etConfirmationAlerts`
MajorLift 0e10ad7
Add `eslint-disable` directives for `rules-of-hooks`
MajorLift d3c1f6e
Rename: `{s,useS}yncConfirmPath`
MajorLift 4abb021
Merge branch 'main' into jongsun/chore/251030-enable-rules-of-hooks
MajorLift da42adc
Fix conditional hook calls introduced from main
MajorLift 8fd5794
Fix incorrectly resolved merge conflict
MajorLift 8933eb6
Set up React Compiler
MajorLift 435d46f
Fix formatting rule violations
MajorLift 3d6ddc1
Fix logical rule violations
MajorLift 8f719cb
Fix breakages
MajorLift 3520c5b
Merge branch 'main' into jongsun/chore/251030-enable-rules-of-hooks
MajorLift 81d2550
Merge branch 'main' into jongsun/chore/251030-enable-rules-of-hooks
MajorLift a416f2c
Refactor webpack config to have dedicated loader for react compiler
MajorLift e1020cf
Fix lint regression
MajorLift 26474c8
Fix regression from main
MajorLift 885d97d
Fix webpack react compiler loader option object type
MajorLift d2fa283
Fix incorrectly resolved merge conflict
MajorLift 8983be0
Use exact versions for react compiler deps
MajorLift 148a3e1
Merge branch 'jongsun/chore/251030-enable-rules-of-hooks' into jongsu…
MajorLift ca4e8e2
More fixes
MajorLift 958e912
Merge branch 'jongsun/chore/251030-enable-rules-of-hooks' into jongsu…
MajorLift d816c82
Rename `{use,handle}SnapNavigate`
MajorLift b64d7db
lavamoat: Widen `process` nested globals access to top-level scope
MajorLift 2b2fdb4
Update LavaMoat policies
metamaskbot 1a87ae8
Fix ui path in webpack loader
MajorLift 7ed0746
Update LavaMoat policies
metamaskbot 287d5b9
Remove source path exceptions
MajorLift 64a540d
test: Update unit test snapshot
MajorLift 300cdf0
Exclude `typed-sign-permission-util.ts`
MajorLift 2672f02
Fix error from missing `t` in dep array
MajorLift 57b3a75
Fix "Should have a queue" error by opting-out `ui/pages/confirmations…
MajorLift b4be12a
Merge branch 'main' into jongsun/build/251103-enable-react-compiler
MajorLift a07e1b4
Opt-out regression from main
MajorLift 4fa7ca9
Fix incorrect mounting logic
MajorLift c7683cd
Remove unnecessary key prop
MajorLift db50bc8
Fix build config
MajorLift 9c7180f
Merge branch 'main' into jongsun/build/251103-enable-react-compiler
MajorLift a51fdb7
Update LavaMoat policies
metamaskbot d3453be
Merge branch 'main' into jongsun/build/251103-enable-react-compiler
MajorLift 11a605d
Opt-outs
MajorLift 6439755
Add excluded paths
MajorLift 3c917a3
Add react compiler logger for webpack
MajorLift 5e908de
Merge branch 'main' into jongsun/build/251103-enable-react-compiler
MajorLift fae3b64
Update LavaMoat policies
metamaskbot 8ac83e8
Revert webpack config
MajorLift 01c9906
Merge branch 'main' into jongsun/build/251103-enable-react-compiler
MajorLift dbe4c7d
Remove `exhaustive-deps` regression from main
MajorLift 9ed8bca
Update LavaMoat policies
metamaskbot 8521341
Remove `component-library` from excluded paths
MajorLift 1b20e16
Remove webpack entry in `.depcheckrc`
MajorLift 3cd3634
Merge branch 'main' into jongsun/build/251103-enable-react-compiler
MajorLift 249d0ea
Fix faulty fallback logic for confirm alerts state keys
MajorLift 931a675
Bump deps to v1.0
MajorLift d5ab272
Fix `useAsync` mounted check race condition
MajorLift 1339d5c
Add entry to exclude patterns
MajorLift 9916a99
Update LavaMoat policies
metamaskbot 94e10c8
Add deps
MajorLift 66aba3d
Fix HOC-returned component local name
MajorLift e839433
Opt-out `useTokenExchangeRate`
MajorLift 8a491bc
Fix `renderHook` usage in test
MajorLift 2576d4f
Refactor babel config to register react compiler as an override
MajorLift e456d36
Dedupe lockfile
MajorLift b17086f
Revert "Dedupe lockfile"
MajorLift a5acea4
Make regex non-capturing
MajorLift d0321db
Merge branch 'main' into jongsun/build/251103-enable-react-compiler
MajorLift 713aa39
Fix babel config regex to only match top-level `ui/`
MajorLift 478ac1d
Bump `tsx` from `^4.19.2` to `^4.20.6`
MajorLift 0a7f8d6
Merge branch 'main' into jongsun/build/251103-enable-react-compiler
MajorLift a9ce8e9
Update LavaMoat policies
metamaskbot 663a07b
Bump `koa` from `^2.7.0` to `^3.1.1`
MajorLift 08d667a
Update LavaMoat policies
metamaskbot f5674d5
Fix regex
MajorLift 01094ea
Remove unnecessary cleanup
MajorLift 7969aa6
Opt-out confirm alert files
MajorLift 6788b0f
Revert `in` property check
MajorLift 189e390
Revert handling for `background[method]` not function error
MajorLift be6e749
Add missing background method mock
MajorLift dda7ecb
Opt-out `useAssetMetadata`
MajorLift 2455a12
Merge branch 'main' into jongsun/build/251103-enable-react-compiler
MajorLift 9e269b9
Remove opt-out from root
MajorLift c47e3f6
Merge branch 'main' into jongsun/build/251103-enable-react-compiler
MajorLift File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -320,8 +320,9 @@ module.exports = { | |
| jsx: true, | ||
| }, | ||
| }, | ||
| plugins: ['react'], | ||
| plugins: ['react', 'react-compiler'], | ||
| rules: { | ||
| 'react-compiler/react-compiler': 'error', | ||
| 'react/no-unused-prop-types': 'error', | ||
| 'react/no-unused-state': 'error', | ||
| 'react/jsx-boolean-value': 'error', | ||
|
|
@@ -362,8 +363,9 @@ module.exports = { | |
| jsx: true, | ||
| }, | ||
| }, | ||
| plugins: ['react'], | ||
| plugins: ['react', 'react-compiler'], | ||
| rules: { | ||
| 'react-compiler/react-compiler': 'error', | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
| 'react/no-unused-prop-types': 'warn', | ||
| 'react/no-unused-state': 'warn', | ||
| 'react/jsx-boolean-value': 'off', | ||
|
|
||
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
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.