Skip to content

chore: upgrade oxlint to 1.70.0 and enable react/react-compiler rule#10203

Open
reidbarber wants to merge 7 commits into
mainfrom
upgrade-oxlint-1-70-0
Open

chore: upgrade oxlint to 1.70.0 and enable react/react-compiler rule#10203
reidbarber wants to merge 7 commits into
mainfrom
upgrade-oxlint-1-70-0

Conversation

@reidbarber

@reidbarber reidbarber commented Jun 15, 2026

Copy link
Copy Markdown
Member

Upgrades oxlint to 1.70.0, which includes the native react compiler rule.

Benchmark results on M4 Max MPB:

Before (1.63.0 + JS plugin) After (1.70.0 + native)
Wall time ~18.5s ~3.2s
CPU (user) ~31s ~7.3s
Speedup 5.8×

The native rule caught more violations than the JS plugin (585 total vs. 43 total).

Category Count
Refs (ref access during render) 197
Immutability (mutating props/hook values) 150
Hooks (rules of hooks) 85
CapitalizedCalls 83
MemoDependencies 27
EffectSetState 10
PreserveManualMemo 9
StaticComponents, Purity, etc. ~24

I suppressed them in this PR, but we can decide if there's any we want to fix for now.

✅ Pull Request Checklist:

  • Included link to corresponding React Spectrum GitHub Issue.
  • Added/updated unit tests and storybook for this change (for new code or code which already has tests).
  • Filled out test instructions.
  • Updated documentation (if it already exists for this component).
  • Looked at the Accessibility Practices for this feature - Aria Practices

📝 Test Instructions:

🧢 Your Project:

@rspbot

rspbot commented Jun 15, 2026

Copy link
Copy Markdown

@reidbarber reidbarber changed the title chore: upgrade oxlint to 1.70.0 chore: upgrade oxlint to 1.70.0 and enable react/react-compiler rule Jun 15, 2026
}
// eslint-disable-next-line react-hooks/exhaustive-deps
}, [domRef, orientation, scale, setHasOverflow, children]);
// oxlint-enable react/react-compiler, react-hooks/exhaustive-deps

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this appears to be in the wrong place? and it looks like this happened in a number of places

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is oxlint-enable, so it is re-enabling here. That being said, I think we can clean up some of these.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

o, weird 👍🏻

let groupState = useContext(CheckboxGroupContext);
let {labelProps, inputProps, isInvalid, isDisabled} = groupState
? // eslint-disable-next-line react-hooks/rules-of-hooks
// oxlint-disable-next-line react/react-compiler, react-hooks/rules-of-hooks

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the disable on the line above can probably be removed, this happened in a few places as well

@rspbot

rspbot commented Jun 16, 2026

Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants