Improve React Compiler diagnostics with actionable help and cause-oriented labels. Preserve-memoization and recursive-initialization diagnostics previously spanned entire callbacks; they now keep codeframes compact while refs and `try`/`finally` show related locations.
Validated with React Compiler and React linter suites, Clippy, `just ready`, and the 24-rule VS Code ecosystem audit.
AI-assisted: Codex was used to implement and validate this change. I reviewed and take responsibility for the result.
This PR contains the following updates:
| Package | Type | Update | Change |
|---|---|---|---|
|
[sort-package-json](https://redirect.github.com/oxc-project/sort-package-json)
| workspace.dependencies | major | `0.0.15` → `1.0.0` |
---
### Release Notes
<details>
<summary>oxc-project/sort-package-json (sort-package-json)</summary>
###
[`v1.0.0`](https://redirect.github.com/oxc-project/sort-package-json/blob/HEAD/CHANGELOG.md#100---2026-08-16)
[Compare
Source](https://redirect.github.com/oxc-project/sort-package-json/compare/v0.0.15...v1.0.0)
##### Changed
- **Breaking:** Stabilize the public `SortOptions` API and refresh crate
metadata and documentation
([#​158](https://redirect.github.com/oxc-project/sort-package-json/pull/158))
</details>
---
### Configuration
📅 **Schedule**: (in timezone Asia/Shanghai)
- Branch creation
- At any time (no schedule defined)
- Automerge
- At any time (no schedule defined)
🚦 **Automerge**: Enabled.
♻ **Rebasing**: Whenever PR is behind base branch, or you tick the
rebase/retry checkbox.
🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.
---
- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check
this box
---
This PR was generated by [Mend Renovate](https://mend.io/renovate/).
View the [repository job
log](https://developer.mend.io/github/oxc-project/oxc).
<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiI0NC4yOS41IiwidXBkYXRlZEluVmVyIjoiNDQuMjkuNSIsInRhcmdldEJyYW5jaCI6Im1haW4iLCJsYWJlbHMiOltdfQ==-->
---------
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Boshen <boshenc@gmail.com>
Bail out when JSX `ref` values are loaded through properties, matching React Compiler and preserving getter and live-binding evaluation semantics.
The validator previously stopped temporary tracking for every property result inferred as ref-like instead of only stopping for `ref.current`.
Validation: `cargo test -p oxc_react_compiler` and `just ready`.
AI assistance: Codex was used to investigate and prepare this change; the contributor remains responsible for reviewing it before merge.
Queue JSX-outlined components back through the normal `process_fn` pipeline, matching Babel's `Program.ts`. Oxc rebuilds immutable semantics once per FIFO generation and preserves Babel's outlined declaration order.
Validated against the React Compiler fixture suite, Babel output, and `just ready`.
AI-assisted; reviewed and validated by the contributor.
Remove the inactive `react/config` rule and its generated metadata. Oxlint uses fixed, valid React Compiler options, so the rule cannot produce actionable diagnostics.
AI-assisted: Codex was used to implement and validate this change.
Ports Babel's identifier consistency invariant using Oxc's canonical identifier arena and runs it at every equivalent pipeline point.
Validated with the React compiler fixture corpus and clippy.
AI-assisted: Codex was used to implement and verify this change.
Use direct integer formatting for plain graphical snippet coordinates
and line numbers.
Criterion shows 4-14% faster graphical rendering across the covered
cases.
Created with AI assistance.
<sub>Stack created with <a
href="https://github.com/github/gh-stack">GitHub Stacks CLI</a> • <a
href="https://gh.io/stacks-feedback">Give Feedback 💬</a></sub>
Keep diagnostic titles inline and bypass color formatting when the
active style is plain, reducing focused graphical-rendering time by
5–9%.
AI assistance: Codex was used. The contributor remains responsible for
this change.
<sub>Stack created with <a
href="https://github.com/github/gh-stack">GitHub Stacks CLI</a></sub>
Keep common graphical-rendering buffers inline and add a focused
benchmark for regressions.
AI assistance: Codex was used. The contributor remains responsible for
this change.
<sub>Stack created with <a
href="https://github.com/github/gh-stack">GitHub Stacks CLI</a></sub>
Batch graphical diagnostics so reports sharing a source reuse line
indexing, and route oxlint diagnostic batches through the new API.
AI assistance: Codex was used. The contributor remains responsible for
this change.
<sub>Stack created with <a
href="https://github.com/github/gh-stack">GitHub Stacks CLI</a></sub>
Ports Babel's terminal-predecessor invariant and runs it before HIR scope dependency propagation. Keeps terminal successor traversal inline to avoid per-edge heap allocations.
AI-assisted: Codex was used to implement and verify this change.
Ports React Compiler's terminal-successor invariant and runs it after CFG-rewriting passes. Uses the existing upstream `for-return.js` fixture for regression coverage.
AI-assisted: Codex was used to implement and verify this change.
Preserve named function expression names when the private name is unreferenced. This matches React Compiler lowering and avoids changing observable `Function.name` values.
Validated with `just ready`.
AI-assisted.
Improve React Compiler diagnostics with focused primary spans and related labels for declarations, dependencies, effects, nested functions, dynamic Hooks, and transitive ref access. This avoids full-function highlights and fixes zero-width arrow labels when lowered parameter spans are missing.
Validation: `env -u NO_COLOR just ready`.
AI-generated with Codex; reviewed and validated by the contributor.
Fix destructured function and rest parameters that become context variables by lowering them through temporaries before `StoreContext`. This avoids inconsistent `Destructure`/context HIR and compiles supported components correctly.
Validated with `just ready` and runtime equivalence checks against React 19.2.1's compiler runtime.
AI usage: Implemented with assistance from OpenAI Codex.
Fixes#25705
---
JS formatter drops `;` (`EmptyStatement`) in a statement list.
However, this raises a question: how are the surrounding comments handled when it is dropped?
This happens because when the comment cursor retrieves that information from the `span`s of the preceding and following nodes, the `EmptyStatement`, which no longer exists, was the one reporting that position.
Pure refactor.
Move debug asserts that `code` cannot be an empty string into the body of `write` and `writeWithMap`. This makes it clearer what the invariants of these functions are.
Pure refactor. Move setting debug-only state to the end of `write*` functions, instead of start. This makes it clearer that it's setting up state for the _next_ call to reference.
`oxc-codegen`'s current API requires passing in a `SourceMapGenerator` as an option to generate source maps. This is currently really slow, and I imagine we'll want to generate source maps internally (perhaps in Rust), and return a source map string from `printSync` instead.
Alter `printSync`'s return type now, to support that without a breaking change later.
- Before: `function printSync(node: ESTree.Node, options?: Options): string`
- After: `function printSync(node: ESTree.Node, options?: Options): { code: string }`
Later on, it can return `{ code: string, map: string }` and that won't break existing users.
Splits the experimental `react/react-compiler` rule into 24 category-specific rules matching `eslint-plugin-react-hooks` v7.
- Runs React Compiler once per file and routes structured diagnostics to each enabled rule.
- Removes `react/react-compiler` and `reportAllBailouts`, with rules categorized by user-facing lint intent.
- Adds per-rule documentation and deduplicates shared React lint URLs.
- Preserves standardized compiler diagnostics while reporting each finding under its Oxlint rule name.
Breaking change: configurations using `react/react-compiler` must migrate to the category-specific rules.
Written with Claude Code and Codex.
Standardize React Compiler diagnostics with concise titles, primary labels, actionable help, notes, structured categories, and official guidance links.
Preserve React guidance when diagnostics are surfaced through Oxlint, and refresh affected snapshots.
AI-assisted; reviewed and validated by the contributor.
Rejects initialized `let` and `const` declarations in `for...in` during parsing while preserving Annex B's non-strict `var` form.
Adds misc coverage for valid and invalid initializer forms.
Verified with `just ready` and parser conformance.
Closes#25149.
AI-assisted.
Centralizes React compiler diagnostics in explicit `#[cold]` functions and removes the `[ReactCompiler]` prefix, keeping diagnostic formatting off hot paths. Updates related NAPI expectations.
AI assistance was used.
Preserve tagged-template call, aliasing, and mutation effects instead of assuming no-substitution tags are primitive or pure.
Execute opaque or effectful tags unconditionally while retaining memoization only when a configured signature proves a read-only pure call and safe return.
AI-assisted investigation and implementation; reviewed and understood by the contributor.
Allows Miri's transformer checks to access the host clock required by `oxc-browserslist` while preserving strict provenance checks.
This fixes the `baseline_targets` failure caused by isolated `clock_gettime`. The failing target passes with the pinned Miri toolchain.
Quoted constructor methods bypassed the AST-based constructor validation. Validate type parameters after resolving the method key, preserving the AST shape.
Validation: `just ready`, parser conformance, and allocation checks.
Closes#25692.
AI-assisted with Codex.
Preserve inline TypeScript enums as opaque pass-through HIR nodes, matching upstream React Compiler behavior. Apply Oxc-specific raw AST reference renaming, and skip compilation when passthrough would hide nested captures or flatten block-local bindings.
AI-assisted: Codex was used to implement and validate this change.
Adds transformer integration coverage for Baseline Browserslist queries and verifies feature-specific lowering across dated and year-based targets.
Created with AI assistance.
Match the public validation defaults from babel-plugin-react-compiler 1.0 while retaining explicit opt-in for newer validations.
Validated with fixture snapshots and `just ready`.
AI-assisted investigation and implementation; reviewed and understood by the contributor.
React Compiler's JSX reconstruction preserved the HIR identifier expression kind, causing compiler-generated lowercase aliases such as `navTitle` to lower as variable references. Classify reconstructed tags by their emitted JSX spelling while preserving underscore-prefixed component references.
Validation: `cargo test -p oxc_react_compiler`, `cargo clippy -p oxc_react_compiler --all-targets -- -D warnings`, and the transform-react NAPI suite.
AI assistance: OpenAI Codex was used to investigate, implement, and validate this change.
## Summary
- retain the innermost JSX-returning arrow node when detecting HOF components
- report react/display-name on the anonymous inner component instead of the outer HOC factory
- cover the TypeScript curried-HOC reproduction and its disable-next-line behavior
Closes#25618.
## Summary
- report default imports whose local name conflicts with a named local export
- preserve the same-symbol re-export exemption from eslint-plugin-import
- keep matching disable directives live under unused-directive reporting
Fixes#25624
## Summary
- report custom Hooks inside try/catch blocks as conditional
- preserve the same-CFG fast path for ordinary top-level Hooks
- add focused regression coverage for the reported first-operation-in-try case
Closes#25631
## Summary
- default `allowIndirect` to `false`, matching ESLint's `no-eval` behavior
- report bare global `eval` references and declared global-object member access by default
- avoid duplicate diagnostics for direct global calls while preserving `allowIndirect: true`
- add regression coverage, including an ESLint disable-next-line directive
Closes#25619.