Skip to content

Conversation

@zharinov
Copy link
Collaborator

Changes

Replaces ESLint with faster native linters:

  • oxlint - Rust-based linter for JS/TS rules
  • biome - Linter + import organizer

Removed (~10 packages)

  • eslint and all plugins (@typescript-eslint/*, eslint-plugin-import-x, eslint-plugin-promise, @vitest/eslint-plugin, @containerbase/eslint-plugin)
  • eslint.config.mjs

Added

  • .oxlintrc.json with comprehensive rule configuration
  • Custom JS plugin for no-tools-import and test-root-describe rules
  • biome.json for noUndeclaredDependencies, useNamingConvention, useConsistentObjectDefinitions, and organizeImports
  • CI step to check for uncommitted changes after biome fixes
  • Pre-commit hook runs biome to organize imports

Scripts

  • oxlint / oxlint-fix / oxlint-ci - oxlint commands
  • biome / biome-fix / biome-ci - biome commands

Context

  • This doesn't close an Issue, but I accept the risk that this PR may be closed if maintainers disagree with its opening or implementation

AI assistance disclosure

  • Yes — substantive assistance

Documentation (please check one with an [x])

  • I have updated the documentation, or

How I've tested my work (please select one)

  • Code inspection only, or

@zharinov zharinov force-pushed the refactor/eslint-to-oxlint-biome branch 4 times, most recently from 9695b13 to fc89dac Compare January 27, 2026 17:10
@zharinov zharinov closed this Jan 27, 2026
@zharinov zharinov force-pushed the refactor/eslint-to-oxlint-biome branch from fc89dac to 13533f7 Compare January 27, 2026 17:18
@zharinov zharinov reopened this Jan 27, 2026
@jamietanna
Copy link
Contributor

Oof just a few changes 😅

I'm gonna say let's hold off until after v43 (unless we need it for the ESM migration)?

@zharinov
Copy link
Collaborator Author

Hey, I haven't done double-check yet, but feel free to comment anyways

@zharinov
Copy link
Collaborator Author

I'm gonna say let's hold off until after v43 (unless we need it for the ESM migration)?

Don't think we need for ESM.
We have time to think what we need from the new linters.
I think it's not necessarily the 1-to-1 migration, but a chance to review the checks we want.

@@ -1,10 +1,10 @@
.md-header .md-header__button.md-logo {
padding: 0;
padding: 0;
Copy link
Member

Choose a reason for hiding this comment

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

why this change, looks wrong to me

*/
function re2() {
return require('re2');
return require("re2");
Copy link
Member

Choose a reason for hiding this comment

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

no indention change and single quote usage!

if (typeof e === 'string') {
return e;
}
return JSON.stringify(e);
Copy link
Member

Choose a reason for hiding this comment

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

should be done separately

...err,
};
const response: Record<string, unknown> = {};
for (const key of Object.keys(err)) {
Copy link
Member

Choose a reason for hiding this comment

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

separate PR

Copy link
Collaborator

Choose a reason for hiding this comment

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

why are these changes necessary?

Copy link
Collaborator Author

Choose a reason for hiding this comment

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

This file violates "no conditionals in tests", I just asked to reorganize it somehow.

- Restore vi.unmock for mutex in race condition tests
- Use early exit pattern in docker versioning isCompatible
@zharinov zharinov force-pushed the refactor/eslint-to-oxlint-biome branch from 13533f7 to 4df1296 Compare January 28, 2026 15:12
Copy link
Member

@viceice viceice left a comment

Choose a reason for hiding this comment

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

quotes are wrongly changed from single to double 😕

@@ -1,9 +1,9 @@
import type { HostRule } from '../types/index.ts';
Copy link
Member

Choose a reason for hiding this comment

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

needs fix 😁

Copy link
Member

Choose a reason for hiding this comment

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

we should extract a package from it, like i've done for the eslint rules 😁

"jsPlugins": ["./tools/lint/rules.js"],
"categories": {},
"rules": {
"constructor-super": "error",
Copy link
Member

Choose a reason for hiding this comment

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

isn't there some preset support? so we don't need to configure them all manually 🤔

@marklai1998
Copy link

@zharinov
biome also come with decent ts+js rules, any reason dual wielding oxlint and biome?

@zharinov
Copy link
Collaborator Author

biome also come with decent ts+js rules, any reason dual wielding oxlint and biome?

@marklai1998 We don't need just decent set of rules, we want to supersede all the existing eslint rules. If there is at least one rule covered by biome and not covered by oxlint, it's worth to have both. And we have such rule: it's noParameterProperties, which helps us to make sure Renovate could be run with Node without transpiling, or in the Bun runtime.

Another benefit is imports ordering which seems to be more stable with biome at the moment. I could be wrong on this one, though.

Anyways, compared to the eslint overhead, the 10 seconds to run another tool is nothing. This decision should be revised in the future as oxlint matures, but the current focus is having decent modern tooling which does everything eslint does, without requiring 8Gb memory and 3–5 minutes to finish.

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.

5 participants