Commit Graph

2615 Commits

Author SHA1 Message Date
renovate 65a77f1a5f chore(deps): update oxc to ^0.132.0 (#22530)
This PR contains the following updates:

| Package | Change | [Age](https://docs.renovatebot.com/merge-confidence/) | [Adoption](https://docs.renovatebot.com/merge-confidence/) | [Passing](https://docs.renovatebot.com/merge-confidence/) | [Confidence](https://docs.renovatebot.com/merge-confidence/) |
|---|---|---|---|---|---|
| [@oxc-project/types](https://oxc.rs) ([source](https://redirect.github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types)) | [`^0.131.0` → `^0.132.0`](https://renovatebot.com/diffs/npm/@oxc-project%2ftypes/0.131.0/0.132.0) | ![age](https://developer.mend.io/api/mc/badges/age/npm/@oxc-project%2ftypes/0.132.0?slim=true) | ![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@oxc-project%2ftypes/0.132.0?slim=true) | ![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@oxc-project%2ftypes/0.131.0/0.132.0?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@oxc-project%2ftypes/0.131.0/0.132.0?slim=true) |
| [oxc-parser](https://oxc.rs/docs/guide/usage/parser) ([source](https://redirect.github.com/oxc-project/oxc/tree/HEAD/napi/parser)) | [`^0.131.0` → `^0.132.0`](https://renovatebot.com/diffs/npm/oxc-parser/0.131.0/0.132.0) | ![age](https://developer.mend.io/api/mc/badges/age/npm/oxc-parser/0.132.0?slim=true) | ![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/oxc-parser/0.132.0?slim=true) | ![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/oxc-parser/0.131.0/0.132.0?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/oxc-parser/0.131.0/0.132.0?slim=true) |

---

### Release Notes

<details>
<summary>oxc-project/oxc (oxc-parser)</summary>

### [`v0.132.0`](https://redirect.github.com/oxc-project/oxc/compare/564ebbf46f87859fc3cf54fe30178f7cc726a902...63b129182d48e8ca2a8a76310a359ef213f62012)

</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 these updates 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:eyJjcmVhdGVkSW5WZXIiOiI0My4xODIuMiIsInVwZGF0ZWRJblZlciI6IjQzLjE4Mi4yIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6W119-->
2026-05-18 13:16:56 +00:00
oxc-guard[bot] 557020642e release(apps): oxlint v1.66.0 && oxfmt v0.51.0 (#22528)
# Oxlint
### 🚀 Features

- 1ae291e linter/no-underscore-dangle: Add `allowInUsingDeclarations`
option (#22483) (吴杨帆)
- 0440b0f linter/eslint: Implement `id-match` rule (#22379) (Vladislav
Sayapin)
- 65bf119 linter: Implement react no-object-type-as-default-prop
(#22481) (uhyo)
- 2a6ddce linter/eslint: Implement `no-implied-eval` rule (#22391)
(Vladislav Sayapin)
- d3a3c1d linter: Auto detect agents from CLI and transition to the
agent output format (#22068) (Jovi De Croock)
- 625758a linter/vitest: Implement padding-around-after-all-blocks rule
(#21788) (kapobajza)
- 37680b0 linter: Implement react no-unstable-nested-components (#22248)
(Jovi De Croock)
- d8d9c74 linter: Implement import/newline-after-import rule (#19142)
(Ryuya Yanagi)

### 🐛 Bug Fixes

- 3f59e03 linter: Only call rayon/miette/tracing inits once (#21899)
(Matiss Janis Aboltins)
- 602dfd6 linter/promise/no-return-wrap: Detect Promise calls in all
branches (#22474) (zennnnnnn11)
- e182aee linter: Allow dialogs and popovers for no_autofocus (#22289)
(mehm8128)
- 7ffb710 linter/jest/vitest: Jest/no-standalone-expect ignores
additionalTestBlockFunctions option for jest/vitest hooks (#22477)
(kapobajza)
- c6f2d3f linter: Add more expression support for iframe-has-title
(#22460) (mehm8128)
- 5747ff1 linter: Avoid enabling jest with vitest plugin (#22499)
(camc314)
- 863984f linter/no-find-dom-node: Run on all files (#22479) (bab)

### ⚡ Performance

- 2afef79 linter: Optimize `no-loop-func` (#22491) (camchenry)
- 4c9ca72 oxlint: Align walker thread count with rayon pool (#22494)
(Boshen)

### 📚 Documentation

- f7967c7 linter/id-match: Clarify `onlyDeclarations` config docs
(#22523) (camc314)
- 1e0c97f linter: Fix closing code block in documentation for
`padding-around-after-all-blocks` rule. (#22513) (connorshea)
- a9049fd linter: Exclude directly provide autoFocus to dialog pattern
(#22510) (mehm8128)
# Oxfmt
### 🐛 Bug Fixes

- 8ee946f formatter/sort_imports: Use label to classify lines (#22512)
(leaysgur)
- 8c1da44 formatter: Normalize destructuring keys in DCR (#22478)
(camc314)
2026-05-18 12:09:34 +01:00
Matiss Janis Aboltins 3f59e036ff fix(linter): only call rayon/miette/tracing inits once (#21899)
Discord conversation:
https://discord.com/channels/1079625926024900739/1498648746433445988

Long story short: we are looking to move from eslint to oxlint in a
large (>15m LOC) monorepo. Internally we use
[lage](https://microsoft.github.io/lage/) for fast runs of lint +
caching. Eslint exposes a programmatic API that we can use to share the
same instance of eslint across different node processes. Thus saving us
time in startup. However, oxlint does not currently expose a
programmatic API. The workaround: reach deep into oxlint built source to
extract `lint()` API (from `dist/bindings.js`) and use that. Yes - it is
very hacky. But it allows us to use oxlint + lage. Reproduction of this
hacky solution can be found here:
https://github.com/MatissJanis/oxlint-lage-repro

In order for the hacky solution to work: we need to fix a few instances
of panic. Hence the PR.

Full disclosure: this was built using claude code (opus 4.7).

---------

Co-authored-by: Cameron Clark <cameron.clark@hey.com>
2026-05-18 11:01:52 +01:00
Vladislav Sayapin 0440b0f060 feat(linter/eslint): implement id-match rule (#22379)
This PR implements the `eslint/id-match` rule, which enforces a
configured naming regex for identifiers

ESLint ref: https://eslint.org/docs/latest/rules/id-match

Issue: https://github.com/oxc-project/oxc/issues/479

### Behavior Differences from ESLint

This implementation is intentionally stricter in two cases:

- Computed destructuring keys are checked, for example `const {
[bad_name]: x } = obj` and `({ [bad_name]: x } = obj)`, because the
computed key is a normal reference expression, not a binding introduced
by destructuring
- With `properties` enabled, ordinary top-level dynamic import option
keys are checked, for example `import("x", { bad_option: true })`.
Import attributes inside `with { ... }` are still ignored

### TypeScript

TypeScript syntax is supported on a best-effort basis for identifiers
that flow through the same visited AST node kinds and transparent
wrappers such as `as`, `satisfies`, non-null assertions, and
instantiation expressions

This is not a replacement for `@typescript-eslint/naming-convention` or
future tsgolint naming-convention work:
https://github.com/oxc-project/tsgolint/issues/186

### Regex Compatibility

The pattern is compiled with Rust regex syntax. JavaScript-specific
regex features such as lookaround and backreferences are not supported.
Unicode escapes should use Rust syntax, for example `\u{XXXX}`

### Algorithmic Complexity

The generated rule runner limits the hot path to identifier-like AST
nodes:

- `BindingIdentifier`
- `IdentifierReference`
- `IdentifierName`
- `PrivateIdentifier`
- `LabelIdentifier`

Each visited identifier first runs the regex check and returns
immediately when the name matches

For non-default configurations, the hot path is linear in the total
length of checked identifier names, with additional ancestor/context
checks only for failed regex matches

Space complexity is `O(1)` beyond the compiled regex and options. The
hot path does not allocate unless a diagnostic is emitted

The default pattern `^.+$` matches every non-empty identifier name, so
`should_run` skips rule work entirely for the default configuration

### AI Disclosure

Claude Opus 4.7 & Codex GPT 5.5

---------

Co-authored-by: Cameron Clark <cameron.clark@hey.com>
2026-05-18 10:06:02 +01:00
leaysgur dcc6d38330 refactor(oxlint,oxfmt): Use shared/importJsConfig for js config (#22453)
Consolidate the following parts:

- Using native `import()`s
- Specifying `cacheKey`
- Extracting default exports
- Returning hints for TS incompatibility errors
2026-05-18 08:05:48 +00:00
leaysgur 37d49fcd40 refactor(oxlint,oxfmt): Share src-js code via apps/shared (#22452)
New place to share code for use in `src-js`, similar to how `crates/oxc_config` works.

Initially, I considered creating an `apps/oxc_cli` and moving `crates/oxc_config` there. However, it felt unnatural deps for `crates/oxc_linter` -> `apps/oxc_cli`, so I decided to keep the Rust code as is for now and share only the JS code.

Since `apps/shared` exports `.ts` files directly, each app is responsible for bundling them via `@oxapps/shared`. Tests still live in `apps/shared`, so separate CI is also added and hooked by each app.

To start, I've only shared the function that reports TS incompatibility errors. This is just for verification purposes and will be fixed in a later PR.
2026-05-18 07:56:26 +00:00
leaysgur f6114d3f48 refactor(oxfmt): Drop unused resolvePlugins stub (#22518) 2026-05-18 06:31:22 +00:00
uhyo 65bf119f1f feat(linter): implement react no-object-type-as-default-prop (#22481)
> [!NOTE]
>
> **AI disclosure**: Claude Opus 4.7 authored all code changes. I
reviewed all of them.

This PR implements
[react/no-object-type-as-default-prop](https://github.com/jsx-eslint/eslint-plugin-react/blob/master/docs/rules/no-object-type-as-default-prop.md).
That was the only missing piece when I migrated from ESLint 😀

Related: #1022 

## Difference from `eslint-plugin-react`

As a result of pursuing the best possible implementation, it diverges
from `eslint-plugin-react`'s in the following ways.

If we should strictly match the `eslint-plugin-react` behavior, I'm
happy to revise the implementation.

### 1. Flags JSX Fragment as object type

```jsx
// Flagged by ours, not by eslint-plugin-react
function Foo({ icon = <></> }) { return <div /> }
```

### 2. Flags wrapped components

```jsx
// Flagged by ours, not by eslint-plugi-react
const Foo = React.forwardRef(({ items = [] }, ref) => <div ref={ref} />);
```

---------

Co-authored-by: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
2026-05-17 16:48:39 -04:00
Vladislav Sayapin 2a6ddcebd1 feat(linter/eslint): implement no-implied-eval rule (#22391)
Implements the `eslint/no-implied-eval` rule, which disallows
string-evaluating calls through `setTimeout`, `setInterval` and
`execScript`

ESLint ref: https://eslint.org/docs/latest/rules/no-implied-eval

Part of: https://github.com/oxc-project/oxc/issues/479

### AI Disclosure

Claude Opus 4.7 & Codex GPT 5.5

---------

Co-authored-by: Cameron Clark <cameron.clark@hey.com>
2026-05-17 21:36:50 +01:00
Jovi De Croock d3a3c1ddf4 feat(linter): Auto detect agents from CLI and transition to the agent output format (#22068)
## Summary

We start auto-detecting agents running the linter through environment
variables, when we see an agent is running the linter we transition to
using the agent output format to save tokens.

The logic is mirrored from
https://github.com/unjs/std-env/blob/main/src/agents.ts which is used by
vitest and others.

Follow up to https://github.com/oxc-project/oxc/pull/21955

---------

Co-authored-by: Cam McHenry <camchenry@users.noreply.github.com>
2026-05-17 16:08:56 -04:00
Boshen 4c9ca72b5f perf(oxlint): align walker thread count with rayon pool (#22494)
## Summary

- The file walker (`ignore::WalkParallel`) was using its own default thread count (`available_parallelism()`), independent of rayon's pool size. When users pass `--threads=N` to lower rayon's count, the walker still silently spun up a full background pool, adding kernel pressure during the walk phase.
- This brings oxlint in line with oxfmt, which already does the same: `apps/oxfmt/src/cli/walk.rs:416`.

## Measurement

On a 72k-file repo (rolldown) on M3 Max, 8 runs per config:

| Config | Wall | User | Sys |
|---|---|---|---|
| `--threads=14` (default) before | 3.31 s | 2.50 s | 32.0 s |
| `--threads=14` after | 3.21 s | 2.50 s | 29.4 s |
| `--threads=6` before | 1.36 s | 1.88 s | 5.88 s |
| `--threads=6` after | **1.28 s** | 1.84 s | **3.91 s** |

The win is largest when `--threads` is set below `available_parallelism()`: 33% sys-time reduction at `--threads=6`. At default threads it's a small consistency improvement (no behavior change since both pools were already at the same count).

🤖 Generated with [Claude Code](https://claude.com/claude-code)
2026-05-17 17:44:53 +00:00
camc314 5747ff1324 fix(linter): avoid enabling jest with vitest plugin (#22499)
now that jest/vitest rules are split, we don't need to enable jest plugin when vitest plugin is enabled via cli

fixes #22498
2026-05-17 15:24:24 +00:00
kapobajza 625758ab25 feat(linter/vitest): Implement padding-around-after-all-blocks rule (#21788)
Related to: #4656

## Summary

Implements the `vitest/padding-around-after-all-blocks` linter rule,
which enforces a blank line of padding before `afterAll` blocks in test
files. Ports the rule from
[eslint-plugin-vitest](https://github.com/vitest-dev/eslint-plugin-vitest).

## AI disclosure

I used Claude Code to help me with onboarding, since I am unfamiliar
with the code. It explained to me how certain things like
`run_on_jest_node`, `report_missing_padding_before_jest_block`, and
other things work under the hood. I also used it to help me with
generating additional test cases for this rule.
And it also generated this PR description for me as well, based on the
file changes.

## Description

This rule helps keep test files readable by visually separating
`afterAll` hooks from surrounding code.

**Incorrect:**
```js
const thing = 123;
afterAll(() => {});
```

**Correct:**
```js
const thing = 123;

afterAll(() => {});
```

The rule:
- Category: `style`
- Plugin: `vitest`
- Auto-fixable: yes (inserts the missing blank line)
- Runs on Jest/Vitest nodes via `run_on_jest_node`, filters to `Hook`
kind calls named `afterAll`, and delegates reporting to the shared
`report_missing_padding_before_jest_block` helper.

---------

Co-authored-by: Kapobajza <kapobajza@gmail.com>
2026-05-16 14:31:03 -04:00
renovate 723beeabac chore(deps): update oxc to ^0.131.0 (#22467)
This PR contains the following updates:

| Package | Change | [Age](https://docs.renovatebot.com/merge-confidence/) | [Adoption](https://docs.renovatebot.com/merge-confidence/) | [Passing](https://docs.renovatebot.com/merge-confidence/) | [Confidence](https://docs.renovatebot.com/merge-confidence/) |
|---|---|---|---|---|---|
| [@oxc-project/types](https://oxc.rs) ([source](https://redirect.github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types)) | [`^0.130.0` → `^0.131.0`](https://renovatebot.com/diffs/npm/@oxc-project%2ftypes/0.130.0/0.131.0) | ![age](https://developer.mend.io/api/mc/badges/age/npm/@oxc-project%2ftypes/0.131.0?slim=true) | ![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@oxc-project%2ftypes/0.131.0?slim=true) | ![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@oxc-project%2ftypes/0.130.0/0.131.0?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@oxc-project%2ftypes/0.130.0/0.131.0?slim=true) |
| [oxc-parser](https://oxc.rs/docs/guide/usage/parser) ([source](https://redirect.github.com/oxc-project/oxc/tree/HEAD/napi/parser)) | [`^0.130.0` → `^0.131.0`](https://renovatebot.com/diffs/npm/oxc-parser/0.130.0/0.131.0) | ![age](https://developer.mend.io/api/mc/badges/age/npm/oxc-parser/0.131.0?slim=true) | ![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/oxc-parser/0.131.0?slim=true) | ![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/oxc-parser/0.130.0/0.131.0?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/oxc-parser/0.130.0/0.131.0?slim=true) |

---

### Release Notes

<details>
<summary>oxc-project/oxc (oxc-parser)</summary>

### [`v0.131.0`](https://redirect.github.com/oxc-project/oxc/compare/650417ffd02bc60e6fa943b630f642aaf802980f...564ebbf46f87859fc3cf54fe30178f7cc726a902)

</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 these updates 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:eyJjcmVhdGVkSW5WZXIiOiI0My4xNzkuMyIsInVwZGF0ZWRJblZlciI6IjQzLjE3OS4zIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6W119-->
2026-05-16 10:59:23 +00:00
Jovi De Croock 37680b0761 feat(linter): implement react no-unstable-nested-components (#22248)
Contributes to https://github.com/oxc-project/oxc/issues/1022

This implements the
[react/no-unstable-nested-components](https://github.com/jsx-eslint/eslint-plugin-react/tree/master/docs/rules/no-unstable-nested-components.nd)
rule.

> [!NOTE]
> This PR was authored by an LLM (GPT5.5) and reviewed by me
2026-05-15 23:54:31 -04:00
Ryuya Yanagi d8d9c749e3 feat(linter): implement import/newline-after-import rule (#19142)
Implemented the `import/newline-after-import` rule.

- [Original
code](https://github.com/import-js/eslint-plugin-import/blob/main/src/rules/newline-after-import.js)
- [Original
tests](https://github.com/import-js/eslint-plugin-import/blob/main/tests/src/rules/newline-after-import.js)
- [Original
docs](https://github.com/import-js/eslint-plugin-import/blob/main/docs/rules/newline-after-import.md)

## Related issues

https://github.com/oxc-project/oxc/issues/1117

## Disclose AI usage

This PR was written with assistance from Codex.

---------

Co-authored-by: Cameron <cameron.clark@hey.com>
Co-authored-by: Cam McHenry <camchenry@users.noreply.github.com>
2026-05-15 23:37:55 -04:00
oxc-guard[bot] 25e5cbc76f release(apps): oxlint v1.65.0 && oxfmt v0.50.0 (#22458)
# Oxlint
### 🚀 Features

- 5478fb5 linter/jsdoc: Implement `require-throws-description` rule
(#22386) (Mikhail Baev)
- b46d4de linter: Add `--debug` options and add per-rule timing info
(#22282) (camchenry)
- c73225e linter/eslint: Implement `prefer-arrow-callback` rule (#22312)
(박천(Cheon Park))
- de82b59 linter: Add support for `eslint-plugin-jsx-a11y-x` (#22356)
(mehm8128)
- b170da3 linter: Implement no-implicit-globals (#22249) (Jovi De
Croock)
- f44b6c8 linter: Fill schemas `DummyRuleMap` with built-in rules
(#22288) (Sysix)
- 5cdb80d linter/jsx-a11y/: Implement
no-interactive-element-to-noninteractive-role (#22332) (anarefolio)
- 2749422 linter/jsx-a11y: Add no-noninteractive-element-interactions
(#22337) (Pablo Tovar)
- ba2a1d3 linter/jsdoc: Implement `require-throws-type` rule (#22358)
(Mikhail Baev)
- d90729d linter/jsx-a11y: Implement control-has-associated-label
(#21985) (mehm8128)
- 1d04903 linter/jsdoc: Implement `require-yields-type` rule (#22331)
(Mikhail Baev)

### 🐛 Bug Fixes

- 04c4609 linter/no-nullable-type-assertion-style: Mark as suggestion
(#22450) (camc314)
- 1c2b7ec linter/no-unused-vars: Handle shadowed self assignments
(#22387) (camc314)
- 9faa1d5 linter/no-noninteractive-tabindex: Check conditional
expressions (#22435) (camc314)
- 0854b3a linter/prefer-arrow-callback: Preserve TSX generic arrows in
fixer (#22434) (camc314)
- 410b814 linter: Supply `source_type` to codegen fixer (#22433)
(camc314)
- 3c1bb6f linter: Skip per-node dispatch for run_once-only rules in
large files (#22398) (Connor Shea)
- 5206cde linter/no-unused-vars: Improve type-only rest parameters
diagnostic (#22385) (camc314)
- c9a22b5 linter/consistent-function-scoping: Allow imported bindings
(#22384) (camc314)
- c1e966d linter: Report type-only unused parameters in no-unused-vars
(#22368) (camchenry)
- 4818d98 linter: Check whether path is under root before ignoring it
(#20101) (Leonabcd123)
- 41fcdcf linter: Fix rule count not including override rules (#19898)
(Daniel Osmond)
- 59b4f0e linter: Fix 'explicit-module-boundary-types' false positive
with 'allowOverloadFunctions' (#22341) (camchenry)

### ⚡ Performance

- 6d42395 linter: Narrow no-unsafe-optional-chaining dispatch (#22437)
(camchenry)
- 08595fb linter: Optimize no-unreachable (#22397) (camchenry)
- 3b46a8d linter: Optimize `no-loss-of-precision` (#22395) (camchenry)
- b3e2dc9 linter: Optimize `oxc/bad-array-method-on-arguments` (#22393)
(camchenry)

### 📚 Documentation

- dcbf62c linter: Remove some duplicate spaces (#22359) (camc314)
# Oxfmt
### 💥 BREAKING CHANGES

- 21bb5d1 oxfmt: [**BREAKING**] Avoid config pre-scan (#22258)
(leaysgur)

### 🐛 Bug Fixes

- 441d724 oxfmt: Fix "race probe" logic with unit tests (#22378)
(leaysgur)
- e49ee26 formatter: Respect `singleQuote` for jsdoc `import()` type
paths (#22353) (Colin Lienard)
- 43b9978 formatter/sort_imports: Treat subpath imports as internal
(#22440) (leaysgur)
- 7c5cfa0 formatter: Handle jsx trailing comment with parens (#22370)
(leaysgur)
- ac5f120 formatter: Fix erroneous formatting inside a template literal
with parentheses (#22262) (Jovi De Croock)
- 3c53a95 formatter/sort_imports: Handle ignore comment as boundary
(#22369) (leaysgur)
- 4dd83dd oxfmt: Send expandedStates variants as shared refs (#22366)
(leaysgur)
- 055cc61 formatter: Expand JSX logical chain with leading line comment
(#22346) (leaysgur)
- 8046222 formatter: Preserve type alias comment break (#22261) (Jovi De
Croock)

### ⚡ Performance

- 123c493 oxfmt: Reduce more syscalls (#22380) (leaysgur)

Co-authored-by: overlookmotel <557937+overlookmotel@users.noreply.github.com>
2026-05-15 15:40:11 +01:00
leaysgur ddb6eed17e refactor(oxlint): Use oxc_config::find_unique_config_by_readdir (#22447)
Also removed unused functions from `oxc_config`.

As a bonus of sharing the code, the number of syscalls should decrease, resulting in a slight improvement in perf.
2026-05-15 08:36:45 +00:00
leaysgur 8959cd92fe refactor(oxfmt): Use oxc_config::find_unique_config_by_readdir (#22446)
Apply to both root and nested config, with removing originally defined in Oxfmt.
2026-05-15 08:24:24 +00:00
leaysgur 7cb5ac96e1 refactor(oxfmt/lsp): Use shared config resolution api (#22443)
Now, walk_runner (explicit file), stdin_runner and lsp can share the same logic.
2026-05-15 03:28:29 +00:00
leaysgur 70ceea53d1 refactor(oxfmt): Move resolve_file_scope_config into core::config (#22442) 2026-05-15 03:20:29 +00:00
leaysgur 7d42a8beee refactor(oxfmt): Clean up codes and comments (#22404) 2026-05-15 03:20:29 +00:00
leaysgur 123c493797 perf(oxfmt): Reduce more syscalls (#22380)
Lesson learned from: #22232

The code itself in this PR was removed due to architectural changes, but we need to preserve its underlying intent.
2026-05-15 03:20:29 +00:00
leaysgur 441d7249e3 fix(oxfmt): Fix "race probe" logic with unit tests (#22378)
Race probe: A protective measure required to correctly locate the nearest config file without a pre-scan.

The `ignore` crate traverses directories in parallel. Because this behavior is somewhat akin to a DFS and is further influenced by factors like OS resource availability, it is unpredictable.

Consequently, when each file attempts to locate its nearest config, we must prevent it from "settling" for a config further up the directory tree and accidentally adopting the wrong one.
2026-05-15 03:20:28 +00:00
leaysgur 57fd60b026 refactor(oxfmt): Split core/config modules (#22376) 2026-05-15 03:16:00 +00:00
leaysgur 3e9c2bd87d refactor(oxfmt): Fix up config and walk modules (#22375) 2026-05-15 03:07:01 +00:00
leaysgur 21bb5d1c1d perf(oxfmt)!: Avoid config pre-scan (#22258)
Fixes #22250

> I'm benchmarking oxfmt on a big repo with around 50k directories.
> https://github.com/oxc-project/oxc/issues/22225
>
> The changes in this PR improve the times from 3.4s -> 2.8s, so 600ms savings 🎉
> https://github.com/oxc-project/oxc/pull/22258#issuecomment-4406579633

When I tested this on a local repo of about 20k, I didn't see as much improvement as reported, but there was definitely an improvement.

---

> [!WARNING]
> This PR changes the CLI behavior in the following nitch cases.

- When you have nested configs,
- and one of which is invalid,
- and you run it in "write" mode

Previously, the CLI would pre-scan the all config files, so an error would be reported immediately and no files would be formatted at all.

With this PR, while it will still report an error and abort upon finding an invalid config file, it will now proceed to format the files for any parts where a valid config can be applied.

In other words, it is highly unlikely that you will encounter this change.
2026-05-15 02:46:09 +00:00
leaysgur 43b997847b fix(formatter/sort_imports): Treat subpath imports as internal (#22440)
Closes #22371, follows https://github.com/azat-io/eslint-plugin-perfectionist/pull/732

---

As a baseline, while the result effectively follows the behavior of a perfectionist, there is no fundamental reason why it must be done that way.

Node.js subpaths are more flexible and aren't necessarily "internal", you can also alias external modules.

However, I do think it's consistent in the sense that it treats them the same way as other conventions like `@`.
2026-05-15 00:45:24 +00:00
overlookmotel e3b0d54556 refactor(napi/parser, linter/plugins): improve safety of raw transfer interface (#22424)
Add a check that the input passed to raw transfer parser implementations is valid - both in `napi/parser` and in the raw transfer implementation used in Oxlint's `RuleTester`.

Check that `source_start` and `source_len` which are passed from JS side are within bounds of the active region of the `Arena`. This check is not strictly necessary - it's part of the safety contract, and is enforced on JS side - but it's critical as the setup of the `Arena` on Rust side depends on the accuracy of these values. If they were wrong, it could lead to reading/writing out of bounds. The check is cheap, so it seems worthwhile - safety trumps the tiny perf impact here.

The 3rd invariant of these functions is that the bytes in the buffer between `source_start` and `source_start + source_len` represent a valid UTF-8 string. Here a full runtime check isn't appropriate, as it would involve scanning and validating the whole source text string (expensive). But _do_ enable the full check in debug builds (used by raw transfer parser tests, and Oxlint conformance tests).
2026-05-14 22:26:41 +00:00
overlookmotel c2c8f806f9 refactor(napi/parser): raw transfer store source text at end of buffer (#22392)
Oxlint's raw transfer implementation stores the source text at end of the buffer. Prior to this PR `napi/parser` stored source text at the start of the buffer.

Bring `napi/parser` into line with Oxlint, by also storing source text at end of the buffer.

Making all versions of raw transfer that we use align with each other removes complication (all versions now have the same implementation of `deserializeStr`) and also removes some fragile code where it'd be easy to accidentally trigger UB (see the updated comments in `arena/fixed_size/windows.rs` and `arena/alloc_impl.rs`).

Unfortunately, storing source at end of buffer is slightly less efficient than storing it at the start. We'll switch all implementations to storing source at start of buffer when we move to storing all strings (source text and all other strings) together in a single contiguous block. But in meantime, this slight inefficiency is outweighed by the gain in safety.
2026-05-14 22:26:41 +00:00
Mikhail Baev 5478fb5aad feat(linter/jsdoc): implement require-throws-description rule (#22386)
this PR implements `jsdoc/require-throws-description` rule. Unlike
`require-returns-description` and `require-property-description`, this
rule is not listed in the recommended section, so i picked `style`
category for it

[rule doc](https://github.com/gajus/eslint-plugin-jsdoc/blob/main/docs/rules/require-throws-description.md)
[rule source](https://github.com/gajus/eslint-plugin-jsdoc/blob/f631620cc1b5bc948f2dfec4228913d19bb2ec0d/src/index.js#L221)

issue #1170

Co-authored-by: Cameron <cameron.clark@hey.com>
2026-05-14 18:25:49 +01:00
overlookmotel 28be3b2148 test(linter/plugins): fix conformance init script (#22423)
Fix the init script which initializes submodules for Oxlint JS plugins
conformance tests.

The script was broken by upgrade to PNPM 11 (#22224), which made
installing packages which have install scripts a hard error.

Fix by telling PNPM not to run packages' install scripts, but not to
raise an error about it either.
2026-05-14 15:27:05 +01:00
camchenry b46d4dee60 feat(linter): add --debug options and add per-rule timing info (#22282)
- part of https://github.com/oxc-project/oxc/issues/22138

This PR implements two separate but related things:

- A new `--debug` option for the `oxlint` CLI that accepts a comma separated list of flags like `--debug foo,bar,baz`. This allows adding more debug functionality in the future without needing to add lots of individual CLI options.
- A `--debug timings` option that enables per-rule timing information to be recorded and output. This enables determining what the slowest rules are in a single run of the linter in the CLI.

### Rule timings

The primary goal of this altered approach to timing linter rules was: **when timings are not enabled, it doesn't cost any performance.**. To achieve that, we've added a `TIMINGS` const generic argument to all of the core `run`, `run_on_jest_node`, `run_once`, etc. functions in the linter. This creates more code overall, because instead of having a single version of each function, now we have two: one where the compiler optimized it with `TIMINGS = false` and one where `TIMINGS = true`. We then switch between these two paths at runtime by passing `--debug timings`.

So, was this successful? In short, yes. There is no significant difference between `oxlint` in `main` and this PR when it comes to performance, unless you enable per-rule timings (see https://github.com/oxc-project/oxc/pull/22282#issuecomment-4421061041). When you enable timing information, there is a 20-30% overhead in performance. This is because we have to record lots of time information and bookkeeping in hash maps to output the final information. This could be optimized down the line possibly, but it's not a primary goal.

This is also kept fairly generic so that in future PRs we can add support for JS plugin timings and `tsgolint` rule timings as well, if those are available.

Overall, I think the increased maintenance burden is worth it. Even looking at the example output below, I can already see ways to improve specific lint rules for improved performance. It will be invaluable for users to be able to record timing information and submit it to us without requiring them to pull up a profiler and submit a flamegraph profile. This doesn't entirely replace a profiler, but it allows us to get useful information without needing to recompile a binary or install additional tools.

### Example output

Example output from `--debug timings` on the vscode repository (using dev mode, not release build, in case this seems really slow):

```
Found 7790 warnings and 19 errors.
Finished in 16.6s on 6911 files with 95 rules using 8 threads.

Rule timings:
Rule                                                      Time (ms)  Relative    Calls  Source
-------------------------------------------------------  ----------  --------  -------  ------
eslint/no-unused-vars                                      4119.700     22.5%     6681  native
eslint/no-unreachable                                      4116.910     22.5%     6900  native
eslint/no-loss-of-precision                                1329.986      7.3%   168327  native
oxc/bad-array-method-on-arguments                           849.118      4.6%  9749545  native
eslint/no-useless-escape                                    633.403      3.5%   469909  native
eslint/no-nonoctal-decimal-escape                           602.055      3.3%   447866  native
eslint/no-this-before-super                                 467.429      2.6%     3912  native
typescript/no-unsafe-declaration-merging                    429.882      2.4%    20334  native
eslint/no-obj-calls                                         423.232      2.3%   602268  native
eslint/no-useless-backreference                             319.706      1.7%   605544  native
eslint/no-dupe-keys                                         284.629      1.6%   109038  native
eslint/no-unsafe-optional-chaining                          246.120      1.3%  2036313  native
eslint/no-control-regex                                     216.737      1.2%   605544  native
eslint/no-misleading-character-class                        212.035      1.2%   605544  native
eslint/constructor-super                                    172.978      0.9%    11088  native
eslint/no-caller                                            171.227      0.9%   946489  native
eslint/no-const-assign                                      161.911      0.9%   167786  native
unicorn/no-thenable                                         160.821      0.9%   851478  native
eslint/no-iterator                                          155.057      0.8%   975576  native
eslint/no-shadow-restricted-names                           146.540      0.8%     6900  native
eslint/no-dupe-class-members                                135.977      0.7%     4144  native
unicorn/prefer-set-size                                     135.732      0.7%   946489  native
typescript/no-extra-non-null-assertion                      134.364      0.7%  1523512  native
oxc/bad-replace-all-arg                                     123.456      0.7%   551933  native
eslint/no-eval                                              117.968      0.6%   774258  native
oxc/only-used-in-recursion                                  108.291      0.6%   150511  native
unicorn/no-await-in-promise-methods                         103.633      0.6%   551933  native
oxc/bad-min-max-func                                        102.570      0.6%   551933  native
eslint/no-invalid-regexp                                    101.664      0.6%   602268  native
eslint/no-dupe-else-if                                       97.380      0.5%    84274  native
unicorn/prefer-string-starts-ends-with                       94.667      0.5%   551933  native
unicorn/no-invalid-remove-event-listener                     93.116      0.5%   551933  native
oxc/bad-char-at-comparison                                   91.417      0.5%   551933  native
unicorn/no-single-promise-in-promise-methods                 90.413      0.5%   551933  native
eslint/no-extra-boolean-cast                                 90.250      0.5%   613702  native
oxc/number-arg-out-of-range                                  87.906      0.5%   551933  native
eslint/no-import-assign                                      82.042      0.4%    73720  native
unicorn/no-useless-length-check                              81.488      0.4%    42367  native
unicorn/no-useless-spread                                    78.767      0.4%   178577  native
typescript/no-unnecessary-parameter-property-assignment      76.019      0.4%    62949  native
eslint/use-isnan                                             75.399      0.4%   650300  native
eslint/no-unsafe-finally                                     70.008      0.4%    93520  native
unicorn/no-invalid-fetch-options                             68.221      0.4%   602268  native
oxc/const-comparisons                                        54.044      0.3%   131693  native
typescript/no-wrapper-object-types                           52.855      0.3%   221028  native
eslint/no-constant-binary-expression                         48.784      0.3%   131693  native
eslint/no-irregular-whitespace                               39.979      0.2%   476825  native
eslint/no-unassigned-vars                                    34.773      0.2%   167786  native
eslint/no-unused-expressions                                 34.643      0.2%   329941  native
eslint/no-sparse-arrays                                      31.352      0.2%    69539  native
typescript/no-this-alias                                     29.074      0.2%   233601  native
eslint/no-useless-rename                                     28.954      0.2%   142726  native
eslint/no-constant-condition                                 25.769      0.1%   103602  native
typescript/triple-slash-reference                            22.440      0.1%     6798  native
eslint/no-setter-return                                      22.301      0.1%    83251  native
eslint/no-cond-assign                                        22.198      0.1%   172385  native
eslint/no-compare-neg-zero                                   22.107      0.1%    89326  native
eslint/no-global-assign                                      21.885      0.1%     6900  native
typescript/prefer-as-const                                   21.868      0.1%   204458  native
eslint/no-self-assign                                        18.860      0.1%    68783  native
eslint/require-yield                                         17.908      0.1%    80796  native
eslint/no-unused-private-class-members                       17.573      0.1%     4144  native
eslint/no-func-assign                                        17.390      0.1%    80796  native
typescript/prefer-namespace-keyword                          17.112      0.1%      783  native
typescript/no-misused-new                                    15.415      0.1%    30084  native
eslint/no-async-promise-executor                             15.132      0.1%    50335  native
oxc/missing-throw                                            14.423      0.1%    50335  native
oxc/erasing-op                                               13.472      0.1%    89326  native
oxc/bad-comparison-sequence                                  11.513      0.1%    89326  native
eslint/no-delete-var                                          9.966      0.1%    43952  native
oxc/bad-object-literal-comparison                             9.699      0.1%    89326  native
unicorn/no-new-array                                          9.666      0.1%    50335  native
eslint/no-duplicate-case                                      9.498      0.1%     1520  native
oxc/double-comparisons                                        9.466      0.1%    42367  native
eslint/no-unsafe-negation                                     9.424      0.1%    89326  native
eslint/no-class-assign                                        8.982      0.0%    11088  native
unicorn/no-useless-fallback-in-spread                         8.865      0.0%    42367  native
oxc/uninvoked-array-callback                                  8.857      0.0%    50335  native
eslint/no-ex-assign                                           8.852      0.0%     2729  native
typescript/no-duplicate-enum-values                           8.704      0.0%     1507  native
eslint/valid-typeof                                           8.612      0.0%    43952  native
eslint/no-new-native-nonconstructor                           7.647      0.0%    50335  native
eslint/no-empty-character-class                               5.828      0.0%     3276  native
typescript/no-useless-empty-export                            4.494      0.0%    27137  native
unicorn/no-empty-file                                         4.235      0.0%     6900  native
unicorn/no-unnecessary-await                                  3.885      0.0%    31924  native
eslint/no-unused-labels                                       2.308      0.0%     6900  native
eslint/for-direction                                          1.938      0.0%     2837  native
eslint/no-useless-catch                                       1.788      0.0%     3853  native
eslint/getter-return                                          1.754      0.0%     1019  native
typescript/no-non-null-asserted-optional-chain                1.734      0.0%     7549  native
eslint/no-empty-pattern                                       1.226      0.0%     5829  native
eslint/no-debugger                                            0.074      0.0%        1  native
```
2026-05-14 02:38:23 +00:00
박천(Cheon Park) c73225efce feat(linter/eslint): implement prefer-arrow-callback rule (#22312)
this PR implements `eslint/prefer-arrow-callback` rule, passes all
upstream tests (39 pass + 68 fail cases, 51 autofix snapshots).

Highlights:
- Honors `allowNamedFunctions` and `allowUnboundThis` options (defaults
match ESLint).
- Strips `.bind(this)` chains during autofix and re-wraps the arrow in
parens when needed (member access, logical/binary operands).
- Handles optional chaining (`function?.bind(this)`, `foo?.(...)`) and
parenthesized callbacks.

issue #479

**AI Disclosure**: I used AI (Claude) to help with Rust idioms and oxc
internals. All output was reviewed locally; `cargo test -p oxc_linter`,
`cargo clippy -p oxc_linter --no-deps`, and `cargo fmt --check` are
clean.

---------

Co-authored-by: Cam McHenry <camchenry@users.noreply.github.com>
2026-05-12 23:26:12 -04:00
leaysgur 4dd83ddaa0 fix(oxfmt): Send expandedStates variants as shared refs (#22366)
Fixes #22350

Currently, the js-in-vue process involves formatting the code on the Rust side using `oxc_formatter`, converting it into an IR, transforming that into a Prettier `Doc`, serializing it into JSON, and then sending it to the JS side, where it is finally passed to Prettier.

Some types of `Docs` include multiple variations that are selected based on the `printWidth`, and all of these variations were being included as part of the JSON payload.

As a result, deep nesting caused the payload size to grow exponentially, leading to hangs.

This PR resolves the issue by sending these variations separately as shared references.
2026-05-13 01:55:13 +00:00
mehm8128 de82b59feb feat(linter): add support for eslint-plugin-jsx-a11y-x (#22356)
close https://github.com/oxc-project/oxc/issues/22264
2026-05-12 21:50:10 -04:00
Sysix 7daa96bf6d chore(linter): update schema json & config (#22365)
PR https://github.com/oxc-project/oxc/pull/22249 did get merged without a rebase, where https://github.com/oxc-project/oxc/pull/22288 is merged. Updated to schema & config, so it does not fail on main:

https://github.com/oxc-project/oxc/actions/runs/25760586174/job/75660405081
2026-05-12 21:27:09 +00:00
renovate aece7e5112 chore(deps): update dependency oxlint to v1.64.0 (#22362)
This PR contains the following updates:

| Package | Change | [Age](https://docs.renovatebot.com/merge-confidence/) | [Adoption](https://docs.renovatebot.com/merge-confidence/) | [Passing](https://docs.renovatebot.com/merge-confidence/) | [Confidence](https://docs.renovatebot.com/merge-confidence/) |
|---|---|---|---|---|---|
| [oxlint](https://oxc.rs/docs/guide/usage/linter) ([source](https://redirect.github.com/oxc-project/oxc/tree/HEAD/npm/oxlint)) | [`1.63.0` → `1.64.0`](https://renovatebot.com/diffs/npm/oxlint/1.63.0/1.64.0) | ![age](https://developer.mend.io/api/mc/badges/age/npm/oxlint/1.64.0?slim=true) | ![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/oxlint/1.64.0?slim=true) | ![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/oxlint/1.63.0/1.64.0?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/oxlint/1.63.0/1.64.0?slim=true) |

---

### Release Notes

<details>
<summary>oxc-project/oxc (oxlint)</summary>

### [`v1.64.0`](https://redirect.github.com/oxc-project/oxc/blob/HEAD/npm/oxlint/CHANGELOG.md#1640---2026-05-11)

[Compare Source](https://redirect.github.com/oxc-project/oxc/compare/oxlint_v1.63.0...oxlint_v1.64.0)

##### 🚀 Features

- [`fbb8f22`](https://redirect.github.com/oxc-project/oxc/commit/fbb8f22) linter: Support `ignores` in overrides ([#&#8203;22148](https://redirect.github.com/oxc-project/oxc/issues/22148)) (camc314)

##### 🐛 Bug Fixes

- [`25b7017`](https://redirect.github.com/oxc-project/oxc/commit/25b7017) linter: Undocument override `ignores` option ([#&#8203;22213](https://redirect.github.com/oxc-project/oxc/issues/22213)) (camc314)

</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:eyJjcmVhdGVkSW5WZXIiOiI0My4xNzMuNiIsInVwZGF0ZWRJblZlciI6IjQzLjE3My42IiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6W119-->
2026-05-12 19:16:14 +00:00
Sysix f44b6c84af feat(linter): fill schemas DummyRuleMap with built-in rules (#22288)
> This PR enhances Oxlint configuration schema fidelity by expanding `DummyRuleMap` to explicitly list all built-in rules as schema properties (improving editor autocomplete), while adding markdown-renderer filtering to avoid generating massive documentation sections for `rules`.

<img width="632" height="391" alt="grafik" src="https://github.com/user-attachments/assets/732bf81b-b090-429a-8bcd-20f0a6a54aa6" />
2026-05-12 18:51:48 +00:00
Daniel Osmond 41fcdcf5fa fix(linter): Fix rule count not including override rules (#19898)
A fix for issue #19891

---------

Co-authored-by: Cam McHenry <camchenry@users.noreply.github.com>
2026-05-12 10:13:00 -04:00
leaysgur f2c01e17b2 chore(oxfmt): Bump bundled prettier-plugin-svelte version (#22338)
https://github.com/sveltejs/prettier-plugin-svelte/blob/master/CHANGELOG.md#352
2026-05-12 00:45:23 +00:00
renovate cd7d90d276 chore(deps): update oxc to ^0.130.0 (#22330)
This PR contains the following updates:

| Package | Change | [Age](https://docs.renovatebot.com/merge-confidence/) | [Adoption](https://docs.renovatebot.com/merge-confidence/) | [Passing](https://docs.renovatebot.com/merge-confidence/) | [Confidence](https://docs.renovatebot.com/merge-confidence/) |
|---|---|---|---|---|---|
| [@oxc-project/types](https://oxc.rs) ([source](https://redirect.github.com/oxc-project/oxc/tree/HEAD/npm/oxc-types)) | [`^0.129.0` → `^0.130.0`](https://renovatebot.com/diffs/npm/@oxc-project%2ftypes/0.129.0/0.130.0) | ![age](https://developer.mend.io/api/mc/badges/age/npm/@oxc-project%2ftypes/0.130.0?slim=true) | ![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/@oxc-project%2ftypes/0.130.0?slim=true) | ![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/@oxc-project%2ftypes/0.129.0/0.130.0?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/@oxc-project%2ftypes/0.129.0/0.130.0?slim=true) |
| [oxc-parser](https://oxc.rs/docs/guide/usage/parser) ([source](https://redirect.github.com/oxc-project/oxc/tree/HEAD/napi/parser)) | [`^0.129.0` → `^0.130.0`](https://renovatebot.com/diffs/npm/oxc-parser/0.129.0/0.130.0) | ![age](https://developer.mend.io/api/mc/badges/age/npm/oxc-parser/0.130.0?slim=true) | ![adoption](https://developer.mend.io/api/mc/badges/adoption/npm/oxc-parser/0.130.0?slim=true) | ![passing](https://developer.mend.io/api/mc/badges/compatibility/npm/oxc-parser/0.129.0/0.130.0?slim=true) | ![confidence](https://developer.mend.io/api/mc/badges/confidence/npm/oxc-parser/0.129.0/0.130.0?slim=true) |

---

### Release Notes

<details>
<summary>oxc-project/oxc (oxc-parser)</summary>

### [`v0.130.0`](https://redirect.github.com/oxc-project/oxc/blob/HEAD/napi/parser/CHANGELOG.md#01300---2026-05-11)

##### 📚 Documentation

- [`a4a6892`](https://redirect.github.com/oxc-project/oxc/commit/a4a6892) napi/parser: Correct code comment ([#&#8203;22278](https://redirect.github.com/oxc-project/oxc/issues/22278)) (overlookmotel)

</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 these updates 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:eyJjcmVhdGVkSW5WZXIiOiI0My4xNTkuMiIsInVwZGF0ZWRJblZlciI6IjQzLjE1OS4yIiwidGFyZ2V0QnJhbmNoIjoibWFpbiIsImxhYmVscyI6W119-->
2026-05-11 17:03:16 +00:00
oxc-guard[bot] d652a55619 release(apps): oxlint v1.64.0 && oxfmt v0.49.0 (#22318)
# Oxlint
### 💥 BREAKING CHANGES

- 00ce512 oxlint/lsp: [**BREAKING**] Don't fix suggestions on fixAll
code actions & command (#22195) (Sysix)

### 🚀 Features

- 0eeceaf linter/no-unused-vars: Rename parameter with initializer
(#22308) (camc314)
- fa0232b linter/no-unused-vars: Add param rename suggestion (#22285)
(Ryota Misumi)
- ae59305 linter/promise/no-promise-in-callback: Add
`exemptDeclarations` option (#22275) (Mikhail Baev)
- 60bed4a linter: Extends `no-redundant-roles` and
`prefer-tag-over-role` support roles (#22069) (mehm8128)
- 545c80f linter/eslint: Implement `prefer-regex-literals` rule (#22192)
(Mikhail Baev)
- cf86d7a linter: Bulk suppression (#19328) (Said Atrahouch)
- 23abd22 linter/jsx-a11y: Implement
no-noninteractive-element-to-interactive-role (#21264) (Pedro Tainha)
- fbb8f22 linter: Support `ignores` in overrides (#22148) (camc314)
- 5a4414d oxlint/lsp: Support `rulesCustomization` lsp option (#21858)
(Sysix)

### 🐛 Bug Fixes

- 610f4c7 linter/no-unused-vars: Avoid renaming captured vars (#22310)
(camc314)
- 6b50f23 oxlint/cli: Load root config by searching up parent
directories (#22272) (Sysix)
- 31a5de7 linter: Rename override `ignores` to `excludeFiles` (#22283)
(camc314)
- 26d5d7b linter: Add missing vitest/valid-describe-callback
functionality (#22279) (camchenry)
- 784530f linter: `valid-title`: detect `String.raw` strings (#22271)
(Sysix)
- 080d90e linter: Move `no-debugger` fix to suggestion (#22256) (Sysix)
- 25b7017 linter: Undocument override `ignores` option (#22213)
(camc314)
- 7bb00dd linter: Fix role-has-required-aria-props (#22097) (mehm8128)
- d25279e linter/disable-directives: Improve parsing of names,
descriptions (#22184) (camc314)
- a59e447 linter/disable-directives: Ignore invalid enable suffixes
(#22179) (camc314)
- aafef0f ci: Disable bulk supression test on big endian (#22175)
(camc314)
- 281daec linter/vue/define-props-destructuring: Add
`only-when-assigned` config opt (#22142) (camc314)
- 46ab679 linter/plugins: Trim leading newline for partial sources
(#20928) (bab)
- 29ff6d9 linter: Update docs for no_alias_methods rule to be
Vitest-specific and add toThrowError alias (#22129) (camchenry)

### ⚡ Performance

- 9414bee linter/role-has-required-aria-props: Avoid intermediate vec
(#22212) (camc314)
- 3883ea3 linter/no-useless-escape: Drop unnecessary Vec collect
(#22171) (connorshea)
- 42c3029 linter/check-property-names: Replace split-collect-pop-join
with rfind (#22172) (connorshea)
- 9551d53 linter: Remove unnecessary Vec collect in CFG edge traversal
(#22167) (connorshea)
- 26fa2fc linter/aria-role: Remove unnecessary string allocations in run
method (#22168) (connorshea)
- c9ce045 linter/getter-return: Remove unnecessary Vec collect in CFG
edge traversal (#22166) (connorshea)
- 72bd846 linter/no-this-in-sfc: Reorder cheap name check, avoid String
allocation (#22164) (connorshea)

### 📚 Documentation

- 4da212a linter/no-unused-vars: Add docs to
`rename_unused_function_parameter` (#22311) (camc314)
- 27c4628 linter/forbid-dom-props: Escape jsx examples in lint rule docs
(#22254) (4MBL)
- 3f81147 linter: Improve the `react/jsx-key` rule docs. (#22162)
(connorshea)
- 07f03cc linter/consistent-return: Add note about `noImplicitReturns`
coverage (#22156) (camc314)
- 7c1e049 oxlint/lsp: Improve autogenerated lsp docs (#22154) (Sysix)
- 87b3e38 linter: Update docs to be vitest-specific for
consistent-test-it (#22128) (camchenry)
# Oxfmt
### 💥 BREAKING CHANGES

- 5c6c390 oxfmt: [**BREAKING**] Respect more git ignore options, align
with Oxlint (#22210) (leaysgur)

### 🚀 Features

- 6e8e818 oxfmt: Experimental .svelte support (#21700) (leaysgur)

### 🐛 Bug Fixes

- e2a20b6 formatter: Add space after commas in import attributes
(#22274) (Leonabcd123)

### ⚡ Performance

- b756682 oxfmt: Optimize nested config prescan (#22232) (Jovi De
Croock)
- f14e81e formatter/sort_imports: Skip sort for single import runs
(#22204) (leaysgur)
- 32255b1 formatter: Process `ImportDeclaration`s in a run (#22079)
(overlookmotel)

### 📚 Documentation

- 4da6f4c formatter: Correct comment (#22217) (overlookmotel)
- ef3507d formatter/sort_imports: Refresh docs (#22203) (leaysgur)

Co-authored-by: Cameron <cameron.clark@hey.com>
2026-05-11 16:02:53 +01:00
camc314 0e207b5851 fix(linter): remove bulk supressions commands from CLI help (#22328)
we're still having some internal discussion about if this feature should ship.

This PR removes the two flags from the documentation to give us the option to make breaking changes in future.
2026-05-11 14:53:29 +00:00
camc314 5641331731 chore(linter): derive Debug for CliConfigLoadError (#22325) 2026-05-11 14:19:47 +00:00
Sysix 6b50f23ac4 fix(oxlint/cli): load root config by searching up parent directories (#22272)
Allow users to run `oxlint` in a sub package, when the monorepo has a base config.

Example:
`cd project/packages/pack-a && oxlint`

Now it detects the config from `project/.oxlintrc.json`, aligning how the LSP side works.
Aligns too how oxfmt searches config path.

closes https://github.com/oxc-project/oxc/issues/21533
found in https://github.com/voidzero-dev/vite-plus/pull/1378#discussion_r3078146663
2026-05-11 08:09:18 +00:00
leaysgur 838061bf83 test(oxfmt): Update conformance (#22299)
Update html-in-js fixtures.
2026-05-11 07:39:20 +00:00
leaysgur d29c5d60bb test(oxfmt): Arrange conformance fixtures dir (#22297)
Prepare for running conformance on CI as well.
2026-05-11 07:23:46 +00:00
leaysgur 47fb154918 test(oxfmt): Add tests and conformance (#21832) 2026-05-11 01:24:38 +00:00
leaysgur 6e8e8185c0 feat(oxfmt): Experimental .svelte support (#21700)
Part of #19715

Note that:

> Users are required to perform 2 steps below
> 1️⃣ Install svelte/compiler@^5.0.0 and/or @astrojs/compiler@^2.9.1 manually
> 2️⃣ Enable option in config
2026-05-11 01:24:37 +00:00