@eslint-community/eslint-plugin-eslint-comments 4.6.0 → 4.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -17,7 +17,6 @@ module.exports = () => {
17
17
 
18
18
  for (const eslintPath of eslintPaths) {
19
19
  try {
20
- // eslint-disable-next-line @eslint-community/mysticatea/node/global-require
21
20
  const linter = require(eslintPath).Linter
22
21
 
23
22
  if (linter) {
@@ -43,9 +43,9 @@ module.exports = {
43
43
  }
44
44
 
45
45
  const lines = comment.value.match(LINE_PATTERN)
46
- //eslint-disable-next-line require-unicode-regexp
47
46
  const ruleIdPattern = new RegExp(
48
- `([\\s,]|^)${escapeStringRegexp(ruleId)}(?:[\\s,]|$)`
47
+ `([\\s,]|^)${escapeStringRegexp(ruleId)}(?:[\\s,]|$)`,
48
+ "u"
49
49
  )
50
50
 
51
51
  {
@@ -9,6 +9,17 @@ require("../utils/patch")()
9
9
 
10
10
  module.exports = {
11
11
  meta: {
12
+ deprecated: {
13
+ availableUntil: "5.0.0",
14
+ deprecatedSince: "4.7.0",
15
+ message:
16
+ "ESLint now has built-in functionality to report unused `eslint-disable` comments",
17
+ replacedBy: {
18
+ message:
19
+ "You can now use ESLint's built-in `linterOptions.reportUnusedDisabledDirectives` to report unused `eslint-disable` comments",
20
+ url: "https://eslint.org/docs/latest/use/configure/configuration-files#reporting-unused-disable-directives",
21
+ },
22
+ },
12
23
  docs: {
13
24
  description: "disallow unused `eslint-disable` comments",
14
25
  category: "Best Practices",
@@ -16,7 +27,7 @@ module.exports = {
16
27
  url: "https://eslint-community.github.io/eslint-plugin-eslint-comments/rules/no-unused-disable.html",
17
28
  },
18
29
  fixable: null,
19
- // eslint-disable-next-line @eslint-community/mysticatea/eslint-plugin/prefer-message-ids
30
+ // eslint-disable-next-line eslint-plugin/prefer-message-ids
20
31
  messages: {},
21
32
  schema: [],
22
33
  type: "problem",
package/package.json CHANGED
@@ -1,29 +1,49 @@
1
1
  {
2
2
  "name": "@eslint-community/eslint-plugin-eslint-comments",
3
- "version": "4.6.0",
3
+ "version": "4.7.0",
4
4
  "description": "Additional ESLint rules for ESLint directive comments.",
5
- "engines": {
6
- "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
5
+ "keywords": [
6
+ "eslint",
7
+ "eslintplugin",
8
+ "eslint-plugin",
9
+ "plugin",
10
+ "comment",
11
+ "comments",
12
+ "directive",
13
+ "global",
14
+ "globals",
15
+ "exported",
16
+ "eslint-env",
17
+ "eslint-enable",
18
+ "eslint-disable",
19
+ "eslint-disable-line",
20
+ "eslint-disable-next-line"
21
+ ],
22
+ "homepage": "https://github.com/eslint-community/eslint-plugin-eslint-comments#readme",
23
+ "bugs": {
24
+ "url": "https://github.com/eslint-community/eslint-plugin-eslint-comments/issues"
7
25
  },
8
- "main": "index.js",
9
- "types": "./types/index.d.ts",
26
+ "repository": {
27
+ "type": "git",
28
+ "url": "https://github.com/eslint-community/eslint-plugin-eslint-comments"
29
+ },
30
+ "funding": "https://opencollective.com/eslint",
31
+ "license": "MIT",
32
+ "author": "Toru Nagashima",
10
33
  "type": "commonjs",
11
- "files": [
12
- "configs.js",
13
- "lib",
14
- "types"
15
- ],
16
34
  "exports": {
17
- "./package.json": "./package.json",
35
+ ".": {
36
+ "types": "./types/index.d.ts",
37
+ "default": "./index.js"
38
+ },
18
39
  "./configs": {
19
40
  "types": "./types/configs.d.ts",
20
41
  "default": "./configs.js"
21
42
  },
22
- ".": {
23
- "types": "./types/index.d.ts",
24
- "default": "./index.js"
25
- }
43
+ "./package.json": "./package.json"
26
44
  },
45
+ "main": "index.js",
46
+ "types": "./types/index.d.ts",
27
47
  "typesVersions": {
28
48
  "*": {
29
49
  "configs": [
@@ -31,8 +51,30 @@
31
51
  ]
32
52
  }
33
53
  },
34
- "peerDependencies": {
35
- "eslint": "^6.0.0 || ^7.0.0 || ^8.0.0 || ^9.0.0"
54
+ "files": [
55
+ "configs.js",
56
+ "lib",
57
+ "types"
58
+ ],
59
+ "scripts": {
60
+ "check-exports": "attw --pack",
61
+ "clean": "rimraf .nyc_output coverage docs/.vitepress/cache",
62
+ "coverage": "nyc report --reporter lcov && opener coverage/lcov-report/index.html",
63
+ "debug": "mocha \"tests/lib/**/*.js\" --reporter dot --timeout 8000",
64
+ "docs:build": "vitepress build docs",
65
+ "docs:watch": "vitepress dev docs",
66
+ "format": "npm run -s format:prettier -- --write",
67
+ "format:check": "npm run -s format:prettier -- --check",
68
+ "format:prettier": "prettier .",
69
+ "lint": "run-p lint:*",
70
+ "lint:eslint": "eslint lib scripts tests",
71
+ "lint:format": "npm run -s format:check",
72
+ "test": "nyc npm run debug",
73
+ "test:types": "tsc -p tsconfig.json",
74
+ "preversion": "npm test",
75
+ "version": "node scripts/update && git add .",
76
+ "postversion": "git push && git push --tags",
77
+ "watch": "npm run -s test -- --watch --growl"
36
78
  },
37
79
  "dependencies": {
38
80
  "escape-string-regexp": "^4.0.0",
@@ -40,19 +82,23 @@
40
82
  },
41
83
  "devDependencies": {
42
84
  "@arethetypeswrong/cli": "^0.18.2",
43
- "@babel/core": "^7.28.5",
44
- "@babel/eslint-parser": "^7.28.5",
45
- "@eslint-community/eslint-plugin-mysticatea": "^15.8.0",
85
+ "@babel/core": "^7.28.6",
86
+ "@babel/eslint-parser": "^7.28.6",
46
87
  "@eslint/core": "^0.13.0",
47
88
  "@eslint/css": "^0.6.0",
48
- "@types/eslint": "^8",
89
+ "@types/eslint": "^8.56.12",
49
90
  "@types/node": "^14.18.63",
50
91
  "@vuepress/plugin-pwa": "^1.9.10",
51
92
  "cross-spawn": "^7.0.6",
52
93
  "esbuild": "^0.27.2",
53
94
  "eslint": "^8.57.1",
95
+ "eslint-config-prettier": "^10.1.8",
96
+ "eslint-plugin-eslint-plugin": "^5.5.1",
97
+ "eslint-plugin-n": "^15.7.0",
98
+ "eslint-plugin-prettier": "^4.2.5",
54
99
  "expect-type": "^1.3.0",
55
- "mocha": "^10.8.2",
100
+ "globals": "^13.24.0",
101
+ "mocha": "^9.2.2",
56
102
  "monaco-editor": "^0.55.1",
57
103
  "npm-run-all2": "^8.0.4",
58
104
  "nyc": "^15.1.0",
@@ -64,52 +110,10 @@
64
110
  "vite-plugin-eslint4b": "^0.2.5",
65
111
  "vitepress": "^1.6.4"
66
112
  },
67
- "scripts": {
68
- "preversion": "npm test",
69
- "version": "node scripts/update && git add .",
70
- "postversion": "git push && git push --tags",
71
- "clean": "rimraf .nyc_output coverage docs/.vitepress/cache",
72
- "docs:build": "vitepress build docs",
73
- "docs:watch": "vitepress dev docs",
74
- "format": "npm run -s format:prettier -- --write",
75
- "format:prettier": "prettier .",
76
- "format:check": "npm run -s format:prettier -- --check",
77
- "lint": "run-p lint:*",
78
- "lint:eslint": "eslint lib scripts tests",
79
- "lint:format": "npm run -s format:check",
80
- "test": "nyc npm run debug",
81
- "debug": "mocha \"tests/lib/**/*.js\" --reporter dot --timeout 8000",
82
- "test:types": "tsc -p tsconfig.json",
83
- "check-exports": "attw --pack",
84
- "coverage": "nyc report --reporter lcov && opener coverage/lcov-report/index.html",
85
- "watch": "npm run -s test -- --watch --growl"
86
- },
87
- "repository": {
88
- "type": "git",
89
- "url": "https://github.com/eslint-community/eslint-plugin-eslint-comments"
90
- },
91
- "keywords": [
92
- "eslint",
93
- "eslintplugin",
94
- "eslint-plugin",
95
- "plugin",
96
- "comment",
97
- "comments",
98
- "directive",
99
- "global",
100
- "globals",
101
- "exported",
102
- "eslint-env",
103
- "eslint-enable",
104
- "eslint-disable",
105
- "eslint-disable-line",
106
- "eslint-disable-next-line"
107
- ],
108
- "author": "Toru Nagashima",
109
- "license": "MIT",
110
- "bugs": {
111
- "url": "https://github.com/eslint-community/eslint-plugin-eslint-comments/issues"
113
+ "peerDependencies": {
114
+ "eslint": "^6.0.0 || ^7.0.0 || ^8.0.0 || ^9.0.0 || ^10.0.0"
112
115
  },
113
- "homepage": "https://github.com/eslint-community/eslint-plugin-eslint-comments#readme",
114
- "funding": "https://opencollective.com/eslint"
116
+ "engines": {
117
+ "node": "^12.22.0 || ^14.17.0 || >=16.0.0"
118
+ }
115
119
  }