eslint 8.13.0 → 8.17.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.
- package/README.md +17 -12
- package/bin/eslint.js +1 -1
- package/lib/cli-engine/cli-engine.js +2 -4
- package/lib/cli-engine/lint-result-cache.js +1 -1
- package/lib/eslint/eslint.js +3 -3
- package/lib/linter/code-path-analysis/code-path-segment.js +1 -1
- package/lib/linter/code-path-analysis/code-path-state.js +1 -1
- package/lib/linter/code-path-analysis/code-path.js +1 -1
- package/lib/rules/accessor-pairs.js +4 -4
- package/lib/rules/callback-return.js +2 -2
- package/lib/rules/capitalized-comments.js +1 -1
- package/lib/rules/consistent-this.js +1 -1
- package/lib/rules/dot-notation.js +2 -2
- package/lib/rules/function-paren-newline.js +8 -5
- package/lib/rules/global-require.js +3 -3
- package/lib/rules/indent-legacy.js +2 -2
- package/lib/rules/indent.js +45 -13
- package/lib/rules/index.js +1 -0
- package/lib/rules/jsx-quotes.js +1 -1
- package/lib/rules/lines-around-comment.js +3 -3
- package/lib/rules/max-lines.js +2 -2
- package/lib/rules/max-statements.js +1 -1
- package/lib/rules/newline-before-return.js +1 -1
- package/lib/rules/no-bitwise.js +2 -2
- package/lib/rules/no-console.js +1 -1
- package/lib/rules/no-constant-binary-expression.js +500 -0
- package/lib/rules/no-constant-condition.js +4 -197
- package/lib/rules/no-control-regex.js +23 -10
- package/lib/rules/no-empty-function.js +1 -1
- package/lib/rules/no-extra-boolean-cast.js +3 -3
- package/lib/rules/no-extra-semi.js +1 -1
- package/lib/rules/no-global-assign.js +1 -1
- package/lib/rules/no-implicit-coercion.js +8 -8
- package/lib/rules/no-loop-func.js +1 -1
- package/lib/rules/no-magic-numbers.js +3 -3
- package/lib/rules/no-misleading-character-class.js +90 -17
- package/lib/rules/no-mixed-operators.js +1 -1
- package/lib/rules/no-mixed-requires.js +1 -1
- package/lib/rules/no-multi-spaces.js +1 -1
- package/lib/rules/no-native-reassign.js +1 -1
- package/lib/rules/no-new-object.js +1 -1
- package/lib/rules/no-new-wrappers.js +1 -1
- package/lib/rules/no-octal.js +2 -2
- package/lib/rules/no-prototype-builtins.js +3 -3
- package/lib/rules/no-shadow.js +5 -5
- package/lib/rules/no-sparse-arrays.js +1 -1
- package/lib/rules/no-underscore-dangle.js +31 -2
- package/lib/rules/no-unused-expressions.js +1 -1
- package/lib/rules/no-unused-vars.js +1 -1
- package/lib/rules/no-use-before-define.js +15 -2
- package/lib/rules/operator-assignment.js +2 -2
- package/lib/rules/prefer-const.js +1 -1
- package/lib/rules/prefer-reflect.js +2 -2
- package/lib/rules/prefer-regex-literals.js +3 -3
- package/lib/rules/quote-props.js +2 -2
- package/lib/rules/quotes.js +1 -1
- package/lib/rules/spaced-comment.js +1 -1
- package/lib/rules/utils/ast-utils.js +203 -7
- package/lib/rules/valid-jsdoc.js +1 -1
- package/lib/rules/valid-typeof.js +4 -4
- package/lib/rules/yoda.js +1 -1
- package/lib/shared/types.js +1 -1
- package/package.json +25 -8
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "eslint",
|
3
|
-
"version": "8.
|
3
|
+
"version": "8.17.0",
|
4
4
|
"author": "Nicholas C. Zakas <nicholas+npm@nczconsulting.com>",
|
5
5
|
"description": "An AST-based pattern checker for JavaScript.",
|
6
6
|
"bin": {
|
@@ -16,7 +16,9 @@
|
|
16
16
|
"test": "node Makefile.js test",
|
17
17
|
"test:cli": "mocha",
|
18
18
|
"lint": "node Makefile.js lint",
|
19
|
+
"lint:docsjs": "node Makefile.js lintDocsJS",
|
19
20
|
"fix": "node Makefile.js lint -- fix",
|
21
|
+
"fix:docsjs": "node Makefile.js lintDocsJS -- fix",
|
20
22
|
"fuzz": "node Makefile.js fuzz",
|
21
23
|
"generate-release": "node Makefile.js generateRelease",
|
22
24
|
"generate-alpharelease": "node Makefile.js generatePrerelease -- alpha",
|
@@ -25,14 +27,19 @@
|
|
25
27
|
"publish-release": "node Makefile.js publishRelease",
|
26
28
|
"gensite": "node Makefile.js gensite",
|
27
29
|
"webpack": "node Makefile.js webpack",
|
28
|
-
"perf": "node Makefile.js perf"
|
30
|
+
"perf": "node Makefile.js perf",
|
31
|
+
"docs:update-links": "node tools/fetch-docs-links.js"
|
29
32
|
},
|
30
33
|
"gitHooks": {
|
31
34
|
"pre-commit": "lint-staged"
|
32
35
|
},
|
33
36
|
"lint-staged": {
|
34
37
|
"*.js": "eslint --fix",
|
35
|
-
"*.md": "markdownlint"
|
38
|
+
"*.md": "markdownlint --fix",
|
39
|
+
"docs/src/rules/*.md": [
|
40
|
+
"node tools/fetch-docs-links.js",
|
41
|
+
"git add docs/src/_data/further_reading_links.json"
|
42
|
+
]
|
36
43
|
},
|
37
44
|
"files": [
|
38
45
|
"LICENSE",
|
@@ -47,7 +54,7 @@
|
|
47
54
|
"homepage": "https://eslint.org",
|
48
55
|
"bugs": "https://github.com/eslint/eslint/issues/",
|
49
56
|
"dependencies": {
|
50
|
-
"@eslint/eslintrc": "^1.
|
57
|
+
"@eslint/eslintrc": "^1.3.0",
|
51
58
|
"@humanwhocodes/config-array": "^0.9.2",
|
52
59
|
"ajv": "^6.10.0",
|
53
60
|
"chalk": "^4.0.0",
|
@@ -58,14 +65,14 @@
|
|
58
65
|
"eslint-scope": "^7.1.1",
|
59
66
|
"eslint-utils": "^3.0.0",
|
60
67
|
"eslint-visitor-keys": "^3.3.0",
|
61
|
-
"espree": "^9.3.
|
68
|
+
"espree": "^9.3.2",
|
62
69
|
"esquery": "^1.4.0",
|
63
70
|
"esutils": "^2.0.2",
|
64
71
|
"fast-deep-equal": "^3.1.3",
|
65
72
|
"file-entry-cache": "^6.0.1",
|
66
73
|
"functional-red-black-tree": "^1.0.1",
|
67
74
|
"glob-parent": "^6.0.1",
|
68
|
-
"globals": "^13.
|
75
|
+
"globals": "^13.15.0",
|
69
76
|
"ignore": "^5.2.0",
|
70
77
|
"import-fresh": "^3.0.0",
|
71
78
|
"imurmurhash": "^0.1.4",
|
@@ -74,7 +81,7 @@
|
|
74
81
|
"json-stable-stringify-without-jsonify": "^1.0.1",
|
75
82
|
"levn": "^0.4.1",
|
76
83
|
"lodash.merge": "^4.6.2",
|
77
|
-
"minimatch": "^3.
|
84
|
+
"minimatch": "^3.1.2",
|
78
85
|
"natural-compare": "^1.4.0",
|
79
86
|
"optionator": "^0.9.1",
|
80
87
|
"regexpp": "^3.2.0",
|
@@ -96,15 +103,19 @@
|
|
96
103
|
"eslint": "file:.",
|
97
104
|
"eslint-config-eslint": "file:packages/eslint-config-eslint",
|
98
105
|
"eslint-plugin-eslint-comments": "^3.2.0",
|
99
|
-
"eslint-plugin-eslint-plugin": "^4.0
|
106
|
+
"eslint-plugin-eslint-plugin": "^4.2.0",
|
100
107
|
"eslint-plugin-internal-rules": "file:tools/internal-rules",
|
101
108
|
"eslint-plugin-jsdoc": "^37.0.0",
|
102
109
|
"eslint-plugin-node": "^11.1.0",
|
110
|
+
"eslint-plugin-unicorn": "^42.0.0",
|
103
111
|
"eslint-release": "^3.2.0",
|
104
112
|
"eslump": "^3.0.0",
|
105
113
|
"esprima": "^4.0.1",
|
114
|
+
"fast-glob": "^3.2.11",
|
106
115
|
"fs-teardown": "^0.1.3",
|
107
116
|
"glob": "^7.1.6",
|
117
|
+
"got": "^11.8.3",
|
118
|
+
"gray-matter": "^4.0.3",
|
108
119
|
"jsdoc": "^3.5.5",
|
109
120
|
"karma": "^6.1.1",
|
110
121
|
"karma-chrome-launcher": "^3.1.0",
|
@@ -117,6 +128,12 @@
|
|
117
128
|
"markdownlint-cli": "^0.30.0",
|
118
129
|
"marked": "^4.0.8",
|
119
130
|
"memfs": "^3.0.1",
|
131
|
+
"metascraper": "^5.25.7",
|
132
|
+
"metascraper-description": "^5.25.7",
|
133
|
+
"metascraper-image": "^5.29.3",
|
134
|
+
"metascraper-logo": "^5.25.7",
|
135
|
+
"metascraper-logo-favicon": "^5.25.7",
|
136
|
+
"metascraper-title": "^5.25.7",
|
120
137
|
"mocha": "^8.3.2",
|
121
138
|
"mocha-junit-reporter": "^2.0.0",
|
122
139
|
"node-polyfill-webpack-plugin": "^1.0.3",
|