Skip to content

Enable the React Compiler lint rule and bump dependencies#128

Merged
Aias merged 1 commit into
mainfrom
trombley/changelog
Jun 18, 2026
Merged

Enable the React Compiler lint rule and bump dependencies#128
Aias merged 1 commit into
mainfrom
trombley/changelog

Conversation

@Aias

@Aias Aias commented Jun 18, 2026

Copy link
Copy Markdown
Owner

The build already runs the React Compiler, but a component that breaks the Rules of React bails out of optimization silently: no error, just a missed speedup. oxlint 1.70 adds react/react-compiler, which runs the compiler in lint-only mode and reports those bailouts as errors, so lint now enforces what the compiler needs, including the existing convention against hand-written useMemo/useCallback.

Turning the rule on surfaced ten violations, fixed here:

  • media-grid: drops two manual useMemos the compiler couldn't preserve (their dependency was a fresh array each render); the compiler memoizes instead.
  • masonry: moves measured column heights from a render-read ref into state, removing the manual rerender reducer.
  • keyboard shortcuts: swaps the latest-value-in-a-ref patterns for a lazy useState store and useEffectEvent, keeping the global key listener stable without reading refs during render.
  • record-lookup: moves the popover's reset-on-close from an effect into the onOpenChange handler, avoiding a synchronous setState cascade.

Also bumps dependencies, most notably the oxc toolchain (oxlint 1.70 / oxfmt 0.55) that ships the rule, plus minor and patch updates to Base UI, tRPC, lucide-react, openai, and the TanStack packages.

@Aias Aias marked this pull request as ready for review June 18, 2026 20:28
@Aias Aias merged commit 71165a1 into main Jun 18, 2026
2 checks passed
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.

1 participant