Skip to content

chore: replace ESLint with Oxlint - #349

Merged
Mrtenz merged 1 commit into
mainfrom
mrtenz/oxlint
Sep 24, 2026
Merged

Mrtenz merged 1 commit into
mainfrom
mrtenz/oxlint

Conversation

@Mrtenz

@Mrtenz Mrtenz commented Sep 24, 2026 •

Copy link
Copy Markdown
Member

This replaces ESLint with Oxlint, with the intention of matching the ESLint config as closely as possible.

Examples

MetaMask/core#10151


Note

Medium Risk
Large dev-tooling swap can change which issues CI catches versus ESLint, though application/runtime code is untouched.

Overview
Swaps the module template’s primary linter from ESLint to Oxlint, aligned with MetaMask’s shared @metamask/oxlint-config* packages.

eslint.config.mjs is removed and oxlint.config.ts is added with file-based overrides for TypeScript, CommonJS/Node (including scripts and .github), and Vitest/tests, plus type-aware linting via oxlint-tsgolint. lint / lint:fix now run lint:oxlint instead of lint:eslint, and Lavamoat script config is updated to match.

Dev dependencies drop the ESLint core stack (eslint, @metamask/eslint-config-*, typescript-eslint, import/jsdoc/prettier plugins, etc.) in favor of oxlint and the new config packages; eslint-plugin-n remains for the Node oxlint preset. .depcheckrc.json ignores are updated for the new tooling, and yarn.lock reflects the dependency tree change.

Reviewed by Cursor Bugbot for commit 5c914cf. Bugbot is set up for automated code reviews on this repo. Configure here.

@Mrtenz
Mrtenz added this pull request to stack #347 September 24, 2026 12:21
@socket-security

socket-security Bot commented Sep 24, 2026 •

Copy link
Copy Markdown

@Mrtenz
Mrtenz marked this pull request as ready for review September 24, 2026 12:34
@Mrtenz
Mrtenz requested a review from a team as a code owner September 24, 2026 12:34
Base automatically changed from mrtenz/es2022 to main September 24, 2026 12:43
@Mrtenz
Mrtenz merged commit 33eaa9f into main Sep 24, 2026
28 checks passed
@Mrtenz
Mrtenz deleted the mrtenz/oxlint branch September 24, 2026 12:47

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Cursor Bugbot has reviewed your changes and found 2 potential issues.

Fix All in Cursor

Reviewed by Cursor Bugbot for commit 5c914cf. Configure here.

Comment thread .depcheckrc.json
"@yarnpkg/shell",
"eslint-config-*",
"eslint-import-resolver-typescript",
"eslint-plugin-*",

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Depcheck ignores miss oxlint packages

Medium Severity

The ignore list dropped the eslint-plugin-* wildcard and never added oxlint-tsgolint, so eslint-plugin-n and oxlint-tsgolint look unused to depcheck. yarn lint:dependencies fails even though both packages are required peers of the oxlint configs.

Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 5c914cf. Configure here.

Comment thread package.json
"@metamask/oxlint-config-typescript": "^0.1.1",
"@metamask/oxlint-config-vitest": "^0.1.1",
"@types/node": "^18.18",
"@typescript-eslint/utils": "^8.6.0",

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Unused Vitest ESLint plugin remains

Low Severity

@vitest/eslint-plugin remains in devDependencies after the ESLint removal, but @metamask/oxlint-config-vitest does not depend on it, so the package is unused.

Additional Locations (1)
Fix in Cursor Fix in Web

Reviewed by Cursor Bugbot for commit 5c914cf. Configure here.

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.

2 participants