Skip to content

Commit 43d2ac8

Browse files
committed
chore(eslint): upgrade to @eslint-community/eslint-plugin-eslint-comments v4.7.1
Replace deprecated mysticatea/eslint-plugin-eslint-comments v3.2.0 (incompatible with ESLint 10 due to use of removed context.getSourceCode() API) with the actively maintained @eslint-community version. Add eslint-comments/no-unlimited-disable rule to enforce discipline around eslint-disable directives - requires explicit rule specification rather than blanket disables.
1 parent a372acb commit 43d2ac8

3 files changed

Lines changed: 19 additions & 16 deletions

File tree

eslint.config.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
import eslint from "@eslint/js";
22
import type { Linter, Rule } from "eslint";
33
import { defineConfig } from "eslint/config";
4+
import eslintComments from "@eslint-community/eslint-plugin-eslint-comments";
45
import jsdoc from "eslint-plugin-jsdoc";
56
import prettier from "eslint-plugin-prettier/recommended";
67
import tseslint from "typescript-eslint";
@@ -122,6 +123,7 @@ export default defineConfig(
122123
{
123124
plugins: {
124125
barrel: barrelPlugin,
126+
"eslint-comments": eslintComments,
125127
},
126128
rules: {
127129
"prettier/prettier": [
@@ -133,6 +135,7 @@ export default defineConfig(
133135
],
134136
"barrel/no-re-exports": "error",
135137
"barrel/index-re-exports-only": "error",
138+
"eslint-comments/no-unlimited-disable": "error",
136139
},
137140
},
138141
{

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,6 +68,7 @@
6868
"devDependencies": {
6969
"@commitlint/cli": "20.5.0",
7070
"@commitlint/config-conventional": "20.5.0",
71+
"@eslint-community/eslint-plugin-eslint-comments": "4.7.1",
7172
"@eslint/js": "10.0.1",
7273
"@semantic-release/changelog": "6.0.3",
7374
"@semantic-release/git": "10.0.1",
@@ -76,7 +77,6 @@
7677
"conventional-changelog-conventionalcommits": "9.3.0",
7778
"eslint": "10.1.0",
7879
"eslint-config-prettier": "10.1.8",
79-
"eslint-plugin-eslint-comments": "3.2.0",
8080
"eslint-plugin-jsdoc": "62.8.0",
8181
"eslint-plugin-prettier": "5.5.5",
8282
"husky": "9.1.7",

pnpm-lock.yaml

Lines changed: 15 additions & 15 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)