eslint 8.35.0 → 8.36.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 +4 -9
- package/conf/rule-type-list.json +2 -2
- package/lib/cli-engine/file-enumerator.js +6 -4
- package/lib/config/flat-config-array.js +60 -5
- package/lib/eslint/eslint-helpers.js +2 -2
- package/lib/rules/multiline-comment-style.js +42 -3
- package/lib/rules/no-control-regex.js +1 -1
- package/lib/rules/no-extra-boolean-cast.js +1 -1
- package/lib/rules/no-extra-parens.js +1 -1
- package/lib/rules/no-implied-eval.js +1 -1
- package/lib/rules/no-import-assign.js +1 -1
- package/lib/rules/no-invalid-regexp.js +1 -1
- package/lib/rules/no-misleading-character-class.js +2 -2
- package/lib/rules/no-obj-calls.js +1 -1
- package/lib/rules/no-promise-executor-return.js +1 -1
- package/lib/rules/no-regex-spaces.js +1 -1
- package/lib/rules/no-setter-return.js +1 -1
- package/lib/rules/no-useless-backreference.js +2 -2
- package/lib/rules/prefer-exponentiation-operator.js +1 -1
- package/lib/rules/prefer-named-capture-group.js +2 -2
- package/lib/rules/prefer-object-spread.js +1 -1
- package/lib/rules/prefer-regex-literals.js +2 -2
- package/lib/rules/require-unicode-regexp.js +1 -1
- package/lib/rules/wrap-iife.js +1 -1
- package/lib/source-code/source-code.js +1 -1
- package/lib/source-code/token-store/index.js +1 -1
- package/package.json +6 -6
package/README.md
CHANGED
@@ -212,11 +212,6 @@ The people who manage releases, review feature requests, and meet regularly to e
|
|
212
212
|
Nicholas C. Zakas
|
213
213
|
</a>
|
214
214
|
</td><td align="center" valign="top" width="11%">
|
215
|
-
<a href="https://github.com/btmills">
|
216
|
-
<img src="https://github.com/btmills.png?s=75" width="75" height="75"><br />
|
217
|
-
Brandon Mills
|
218
|
-
</a>
|
219
|
-
</td><td align="center" valign="top" width="11%">
|
220
215
|
<a href="https://github.com/mdjermanovic">
|
221
216
|
<img src="https://github.com/mdjermanovic.png?s=75" width="75" height="75"><br />
|
222
217
|
Milos Djermanovic
|
@@ -249,9 +244,9 @@ The people who review and fix bugs and help triage issues.
|
|
249
244
|
Bryan Mishkin
|
250
245
|
</a>
|
251
246
|
</td><td align="center" valign="top" width="11%">
|
252
|
-
<a href="https://github.com/
|
253
|
-
<img src="https://github.com/
|
254
|
-
|
247
|
+
<a href="https://github.com/btmills">
|
248
|
+
<img src="https://github.com/btmills.png?s=75" width="75" height="75"><br />
|
249
|
+
Brandon Mills
|
255
250
|
</a>
|
256
251
|
</td><td align="center" valign="top" width="11%">
|
257
252
|
<a href="https://github.com/fasttime">
|
@@ -297,7 +292,7 @@ The following companies, organizations, and individuals support ESLint's ongoing
|
|
297
292
|
<h3>Platinum Sponsors</h3>
|
298
293
|
<p><a href="#"><img src="https://images.opencollective.com/2021-frameworks-fund/logo.png" alt="Chrome Frameworks Fund" height="undefined"></a> <a href="https://automattic.com"><img src="https://images.opencollective.com/automattic/d0ef3e1/logo.png" alt="Automattic" height="undefined"></a></p><h3>Gold Sponsors</h3>
|
299
294
|
<p><a href="https://ridicorp.com/career/"><img src="https://images.opencollective.com/ridi-corporation/175dcf3/logo.png" alt="RIDI" height="96"></a> <a href="https://engineering.salesforce.com"><img src="https://images.opencollective.com/salesforce/ca8f997/logo.png" alt="Salesforce" height="96"></a> <a href="https://www.airbnb.com/"><img src="https://images.opencollective.com/airbnb/d327d66/logo.png" alt="Airbnb" height="96"></a></p><h3>Silver Sponsors</h3>
|
300
|
-
<p><a href="https://sentry.io"><img src="https://avatars.githubusercontent.com/u/1396951?v=4" alt="Sentry" height="64"></a> <a href="https://liftoff.io/"><img src="https://images.opencollective.com/liftoff/5c4fa84/logo.png" alt="Liftoff" height="64"></a></p><h3>Bronze Sponsors</h3>
|
295
|
+
<p><a href="https://sentry.io"><img src="https://avatars.githubusercontent.com/u/1396951?v=4" alt="Sentry" height="64"></a> <a href="https://liftoff.io/"><img src="https://images.opencollective.com/liftoff/5c4fa84/logo.png" alt="Liftoff" height="64"></a> <a href="https://americanexpress.io"><img src="https://avatars.githubusercontent.com/u/3853301?v=4" alt="American Express" height="64"></a></p><h3>Bronze Sponsors</h3>
|
301
296
|
<p><a href="https://paydaysay.com/"><img src="https://images.opencollective.com/payday-say-organization/9cd2467/logo.png" alt="PayDay Say" height="32"></a> <a href="https://themeisle.com"><img src="https://images.opencollective.com/themeisle/d5592fe/logo.png" alt="ThemeIsle" height="32"></a> <a href="https://nx.dev"><img src="https://images.opencollective.com/nx/0efbe42/logo.png" alt="Nx (by Nrwl)" height="32"></a> <a href="https://www.crosswordsolver.org/anagram-solver/"><img src="https://images.opencollective.com/anagram-solver/2666271/logo.png" alt="Anagram Solver" height="32"></a> <a href="https://icons8.com"><img src="https://images.opencollective.com/icons8/7fa1641/logo.png" alt="Icons8: free icons, photos, illustrations, and music" height="32"></a> <a href="https://discord.com"><img src="https://images.opencollective.com/discordapp/f9645d9/logo.png" alt="Discord" height="32"></a> <a href="https://transloadit.com/"><img src="https://avatars.githubusercontent.com/u/125754?v=4" alt="Transloadit" height="32"></a> <a href="https://www.ignitionapp.com"><img src="https://avatars.githubusercontent.com/u/5753491?v=4" alt="Ignition" height="32"></a> <a href="https://herocoders.com"><img src="https://avatars.githubusercontent.com/u/37549774?v=4" alt="HeroCoders" height="32"></a> <a href="https://quickbookstoolhub.com"><img src="https://avatars.githubusercontent.com/u/95090305?u=e5bc398ef775c9ed19f955c675cdc1fb6abf01df&v=4" alt="QuickBooks Tool hub" height="32"></a></p>
|
302
297
|
<!--sponsorsend-->
|
303
298
|
|
package/conf/rule-type-list.json
CHANGED
@@ -6,12 +6,12 @@
|
|
6
6
|
],
|
7
7
|
"deprecated": {
|
8
8
|
"name": "Deprecated",
|
9
|
-
"description": "These rules have been deprecated in accordance with the <a href=\"/
|
9
|
+
"description": "These rules have been deprecated in accordance with the <a href=\"{{ '/use/rule-deprecation' | url }}\">deprecation policy</a>, and replaced by newer rules:",
|
10
10
|
"rules": []
|
11
11
|
},
|
12
12
|
"removed": {
|
13
13
|
"name": "Removed",
|
14
|
-
"description": "These rules from older versions of ESLint (before the <a href=\"/
|
14
|
+
"description": "These rules from older versions of ESLint (before the <a href=\"{{ '/use/rule-deprecation' | url }}\">deprecation policy</a> existed) have been replaced by newer rules:",
|
15
15
|
"rules": [
|
16
16
|
{ "removed": "generator-star", "replacedBy": ["generator-star-spacing"] },
|
17
17
|
{ "removed": "global-strict", "replacedBy": ["strict"] },
|
@@ -349,7 +349,7 @@ class FileEnumerator {
|
|
349
349
|
return this._iterateFilesWithFile(absolutePath);
|
350
350
|
}
|
351
351
|
if (globInputPaths && isGlobPattern(pattern)) {
|
352
|
-
return this._iterateFilesWithGlob(
|
352
|
+
return this._iterateFilesWithGlob(pattern, isDot);
|
353
353
|
}
|
354
354
|
|
355
355
|
return [];
|
@@ -398,15 +398,17 @@ class FileEnumerator {
|
|
398
398
|
_iterateFilesWithGlob(pattern, dotfiles) {
|
399
399
|
debug(`Glob: ${pattern}`);
|
400
400
|
|
401
|
-
const
|
402
|
-
const
|
401
|
+
const { cwd } = internalSlotsMap.get(this);
|
402
|
+
const directoryPath = path.resolve(cwd, getGlobParent(pattern));
|
403
|
+
const absolutePath = path.resolve(cwd, pattern);
|
404
|
+
const globPart = absolutePath.slice(directoryPath.length + 1);
|
403
405
|
|
404
406
|
/*
|
405
407
|
* recursive if there are `**` or path separators in the glob part.
|
406
408
|
* Otherwise, patterns such as `src/*.js`, it doesn't need recursive.
|
407
409
|
*/
|
408
410
|
const recursive = /\*\*|\/|\\/u.test(globPart);
|
409
|
-
const selector = new Minimatch(
|
411
|
+
const selector = new Minimatch(absolutePath, minimatchOpts);
|
410
412
|
|
411
413
|
debug(`recursive? ${recursive}`);
|
412
414
|
|
@@ -36,6 +36,45 @@ function splitPluginIdentifier(identifier) {
|
|
36
36
|
};
|
37
37
|
}
|
38
38
|
|
39
|
+
/**
|
40
|
+
* Returns the name of an object in the config by reading its `meta` key.
|
41
|
+
* @param {Object} object The object to check.
|
42
|
+
* @returns {string?} The name of the object if found or `null` if there
|
43
|
+
* is no name.
|
44
|
+
*/
|
45
|
+
function getObjectId(object) {
|
46
|
+
|
47
|
+
// first check old-style name
|
48
|
+
let name = object.name;
|
49
|
+
|
50
|
+
if (!name) {
|
51
|
+
|
52
|
+
if (!object.meta) {
|
53
|
+
return null;
|
54
|
+
}
|
55
|
+
|
56
|
+
name = object.meta.name;
|
57
|
+
|
58
|
+
if (!name) {
|
59
|
+
return null;
|
60
|
+
}
|
61
|
+
}
|
62
|
+
|
63
|
+
// now check for old-style version
|
64
|
+
let version = object.version;
|
65
|
+
|
66
|
+
if (!version) {
|
67
|
+
version = object.meta && object.meta.version;
|
68
|
+
}
|
69
|
+
|
70
|
+
// if there's a version then append that
|
71
|
+
if (version) {
|
72
|
+
return `${name}@${version}`;
|
73
|
+
}
|
74
|
+
|
75
|
+
return name;
|
76
|
+
}
|
77
|
+
|
39
78
|
const originalBaseConfig = Symbol("originalBaseConfig");
|
40
79
|
|
41
80
|
//-----------------------------------------------------------------------------
|
@@ -151,16 +190,25 @@ class FlatConfigArray extends ConfigArray {
|
|
151
190
|
|
152
191
|
// Check parser value
|
153
192
|
if (languageOptions && languageOptions.parser) {
|
154
|
-
|
155
|
-
|
193
|
+
const { parser } = languageOptions;
|
194
|
+
|
195
|
+
if (typeof parser === "string") {
|
196
|
+
const { pluginName, objectName: localParserName } = splitPluginIdentifier(parser);
|
156
197
|
|
157
|
-
parserName =
|
198
|
+
parserName = parser;
|
158
199
|
|
159
200
|
if (!plugins || !plugins[pluginName] || !plugins[pluginName].parsers || !plugins[pluginName].parsers[localParserName]) {
|
160
201
|
throw new TypeError(`Key "parser": Could not find "${localParserName}" in plugin "${pluginName}".`);
|
161
202
|
}
|
162
203
|
|
163
204
|
languageOptions.parser = plugins[pluginName].parsers[localParserName];
|
205
|
+
} else if (typeof parser === "object") {
|
206
|
+
parserName = getObjectId(parser);
|
207
|
+
|
208
|
+
if (!parserName) {
|
209
|
+
invalidParser = true;
|
210
|
+
}
|
211
|
+
|
164
212
|
} else {
|
165
213
|
invalidParser = true;
|
166
214
|
}
|
@@ -178,6 +226,13 @@ class FlatConfigArray extends ConfigArray {
|
|
178
226
|
}
|
179
227
|
|
180
228
|
config.processor = plugins[pluginName].processors[localProcessorName];
|
229
|
+
} else if (typeof processor === "object") {
|
230
|
+
processorName = getObjectId(processor);
|
231
|
+
|
232
|
+
if (!processorName) {
|
233
|
+
invalidProcessor = true;
|
234
|
+
}
|
235
|
+
|
181
236
|
} else {
|
182
237
|
invalidProcessor = true;
|
183
238
|
}
|
@@ -191,11 +246,11 @@ class FlatConfigArray extends ConfigArray {
|
|
191
246
|
value: function() {
|
192
247
|
|
193
248
|
if (invalidParser) {
|
194
|
-
throw new Error("
|
249
|
+
throw new Error("Could not serialize parser object (missing 'meta' object).");
|
195
250
|
}
|
196
251
|
|
197
252
|
if (invalidProcessor) {
|
198
|
-
throw new Error("
|
253
|
+
throw new Error("Could not serialize processor object (missing 'meta' object).");
|
199
254
|
}
|
200
255
|
|
201
256
|
return {
|
@@ -526,9 +526,9 @@ async function findFiles({
|
|
526
526
|
}
|
527
527
|
|
528
528
|
// save patterns for later use based on whether globs are enabled
|
529
|
-
if (globInputPaths && isGlobPattern(
|
529
|
+
if (globInputPaths && isGlobPattern(pattern)) {
|
530
530
|
|
531
|
-
const basePath = globParent(
|
531
|
+
const basePath = path.resolve(cwd, globParent(pattern));
|
532
532
|
|
533
533
|
// group in cwd if possible and split out others
|
534
534
|
if (isPathInside(basePath, cwd)) {
|
@@ -22,7 +22,37 @@ module.exports = {
|
|
22
22
|
},
|
23
23
|
|
24
24
|
fixable: "whitespace",
|
25
|
-
schema:
|
25
|
+
schema: {
|
26
|
+
anyOf: [
|
27
|
+
{
|
28
|
+
type: "array",
|
29
|
+
items: [
|
30
|
+
{
|
31
|
+
enum: ["starred-block", "bare-block"]
|
32
|
+
}
|
33
|
+
],
|
34
|
+
additionalItems: false
|
35
|
+
},
|
36
|
+
{
|
37
|
+
type: "array",
|
38
|
+
items: [
|
39
|
+
{
|
40
|
+
enum: ["separate-lines"]
|
41
|
+
},
|
42
|
+
{
|
43
|
+
type: "object",
|
44
|
+
properties: {
|
45
|
+
checkJSDoc: {
|
46
|
+
type: "boolean"
|
47
|
+
}
|
48
|
+
},
|
49
|
+
additionalProperties: false
|
50
|
+
}
|
51
|
+
],
|
52
|
+
additionalItems: false
|
53
|
+
}
|
54
|
+
]
|
55
|
+
},
|
26
56
|
messages: {
|
27
57
|
expectedBlock: "Expected a block comment instead of consecutive line comments.",
|
28
58
|
expectedBareBlock: "Expected a block comment without padding stars.",
|
@@ -37,6 +67,8 @@ module.exports = {
|
|
37
67
|
create(context) {
|
38
68
|
const sourceCode = context.getSourceCode();
|
39
69
|
const option = context.options[0] || "starred-block";
|
70
|
+
const params = context.options[1] || {};
|
71
|
+
const checkJSDoc = !!params.checkJSDoc;
|
40
72
|
|
41
73
|
//----------------------------------------------------------------------
|
42
74
|
// Helpers
|
@@ -333,11 +365,18 @@ module.exports = {
|
|
333
365
|
"separate-lines"(commentGroup) {
|
334
366
|
const [firstComment] = commentGroup;
|
335
367
|
|
336
|
-
|
368
|
+
const isJSDoc = isJSDocComment(commentGroup);
|
369
|
+
|
370
|
+
if (firstComment.type !== "Block" || (!checkJSDoc && isJSDoc)) {
|
337
371
|
return;
|
338
372
|
}
|
339
373
|
|
340
|
-
|
374
|
+
let commentLines = getCommentLines(commentGroup);
|
375
|
+
|
376
|
+
if (isJSDoc) {
|
377
|
+
commentLines = commentLines.slice(1, commentLines.length - 1);
|
378
|
+
}
|
379
|
+
|
341
380
|
const tokenAfter = sourceCode.getTokenAfter(firstComment, { includeComments: true });
|
342
381
|
|
343
382
|
if (tokenAfter && firstComment.loc.end.line === tokenAfter.loc.start.line) {
|
@@ -10,7 +10,7 @@
|
|
10
10
|
//------------------------------------------------------------------------------
|
11
11
|
|
12
12
|
const astUtils = require("./utils/ast-utils");
|
13
|
-
const eslintUtils = require("eslint-utils");
|
13
|
+
const eslintUtils = require("@eslint-community/eslint-utils");
|
14
14
|
|
15
15
|
const precedence = astUtils.getPrecedence;
|
16
16
|
|
@@ -8,7 +8,7 @@
|
|
8
8
|
// Rule Definition
|
9
9
|
//------------------------------------------------------------------------------
|
10
10
|
|
11
|
-
const { isParenthesized: isParenthesizedRaw } = require("eslint-utils");
|
11
|
+
const { isParenthesized: isParenthesizedRaw } = require("@eslint-community/eslint-utils");
|
12
12
|
const astUtils = require("./utils/ast-utils.js");
|
13
13
|
|
14
14
|
/** @type {import('../shared/types').Rule} */
|
@@ -10,7 +10,7 @@
|
|
10
10
|
//------------------------------------------------------------------------------
|
11
11
|
|
12
12
|
const astUtils = require("./utils/ast-utils");
|
13
|
-
const { getStaticValue } = require("eslint-utils");
|
13
|
+
const { getStaticValue } = require("@eslint-community/eslint-utils");
|
14
14
|
|
15
15
|
//------------------------------------------------------------------------------
|
16
16
|
// Rule Definition
|
@@ -9,7 +9,7 @@
|
|
9
9
|
// Helpers
|
10
10
|
//------------------------------------------------------------------------------
|
11
11
|
|
12
|
-
const { findVariable } = require("eslint-utils");
|
12
|
+
const { findVariable } = require("@eslint-community/eslint-utils");
|
13
13
|
const astUtils = require("./utils/ast-utils");
|
14
14
|
|
15
15
|
const WellKnownMutationFunctions = {
|
@@ -8,7 +8,7 @@
|
|
8
8
|
// Requirements
|
9
9
|
//------------------------------------------------------------------------------
|
10
10
|
|
11
|
-
const RegExpValidator = require("regexpp").RegExpValidator;
|
11
|
+
const RegExpValidator = require("@eslint-community/regexpp").RegExpValidator;
|
12
12
|
const validator = new RegExpValidator();
|
13
13
|
const validFlags = /[dgimsuy]/gu;
|
14
14
|
const undefined1 = void 0;
|
@@ -3,8 +3,8 @@
|
|
3
3
|
*/
|
4
4
|
"use strict";
|
5
5
|
|
6
|
-
const { CALL, CONSTRUCT, ReferenceTracker, getStringIfConstant } = require("eslint-utils");
|
7
|
-
const { RegExpValidator, RegExpParser, visitRegExpAST } = require("regexpp");
|
6
|
+
const { CALL, CONSTRUCT, ReferenceTracker, getStringIfConstant } = require("@eslint-community/eslint-utils");
|
7
|
+
const { RegExpValidator, RegExpParser, visitRegExpAST } = require("@eslint-community/regexpp");
|
8
8
|
const { isCombiningCharacter, isEmojiModifier, isRegionalIndicatorSymbol, isSurrogatePair } = require("./utils/unicode");
|
9
9
|
const astUtils = require("./utils/ast-utils.js");
|
10
10
|
|
@@ -9,7 +9,7 @@
|
|
9
9
|
// Requirements
|
10
10
|
//------------------------------------------------------------------------------
|
11
11
|
|
12
|
-
const { CALL, CONSTRUCT, ReferenceTracker } = require("eslint-utils");
|
12
|
+
const { CALL, CONSTRUCT, ReferenceTracker } = require("@eslint-community/eslint-utils");
|
13
13
|
const getPropertyName = require("./utils/ast-utils").getStaticPropertyName;
|
14
14
|
|
15
15
|
//------------------------------------------------------------------------------
|
@@ -9,7 +9,7 @@
|
|
9
9
|
// Requirements
|
10
10
|
//------------------------------------------------------------------------------
|
11
11
|
|
12
|
-
const { findVariable } = require("eslint-utils");
|
12
|
+
const { findVariable } = require("@eslint-community/eslint-utils");
|
13
13
|
|
14
14
|
//------------------------------------------------------------------------------
|
15
15
|
// Helpers
|
@@ -10,7 +10,7 @@
|
|
10
10
|
//------------------------------------------------------------------------------
|
11
11
|
|
12
12
|
const astUtils = require("./utils/ast-utils");
|
13
|
-
const regexpp = require("regexpp");
|
13
|
+
const regexpp = require("@eslint-community/regexpp");
|
14
14
|
|
15
15
|
//------------------------------------------------------------------------------
|
16
16
|
// Helpers
|
@@ -10,7 +10,7 @@
|
|
10
10
|
//------------------------------------------------------------------------------
|
11
11
|
|
12
12
|
const astUtils = require("./utils/ast-utils");
|
13
|
-
const { findVariable } = require("eslint-utils");
|
13
|
+
const { findVariable } = require("@eslint-community/eslint-utils");
|
14
14
|
|
15
15
|
//------------------------------------------------------------------------------
|
16
16
|
// Helpers
|
@@ -9,8 +9,8 @@
|
|
9
9
|
// Requirements
|
10
10
|
//------------------------------------------------------------------------------
|
11
11
|
|
12
|
-
const { CALL, CONSTRUCT, ReferenceTracker, getStringIfConstant } = require("eslint-utils");
|
13
|
-
const { RegExpParser, visitRegExpAST } = require("regexpp");
|
12
|
+
const { CALL, CONSTRUCT, ReferenceTracker, getStringIfConstant } = require("@eslint-community/eslint-utils");
|
13
|
+
const { RegExpParser, visitRegExpAST } = require("@eslint-community/regexpp");
|
14
14
|
|
15
15
|
//------------------------------------------------------------------------------
|
16
16
|
// Helpers
|
@@ -10,7 +10,7 @@
|
|
10
10
|
//------------------------------------------------------------------------------
|
11
11
|
|
12
12
|
const astUtils = require("./utils/ast-utils");
|
13
|
-
const { CALL, ReferenceTracker } = require("eslint-utils");
|
13
|
+
const { CALL, ReferenceTracker } = require("@eslint-community/eslint-utils");
|
14
14
|
|
15
15
|
//------------------------------------------------------------------------------
|
16
16
|
// Helpers
|
@@ -14,8 +14,8 @@ const {
|
|
14
14
|
CONSTRUCT,
|
15
15
|
ReferenceTracker,
|
16
16
|
getStringIfConstant
|
17
|
-
} = require("eslint-utils");
|
18
|
-
const regexpp = require("regexpp");
|
17
|
+
} = require("@eslint-community/eslint-utils");
|
18
|
+
const regexpp = require("@eslint-community/regexpp");
|
19
19
|
|
20
20
|
//------------------------------------------------------------------------------
|
21
21
|
// Helpers
|
@@ -10,8 +10,8 @@
|
|
10
10
|
//------------------------------------------------------------------------------
|
11
11
|
|
12
12
|
const astUtils = require("./utils/ast-utils");
|
13
|
-
const { CALL, CONSTRUCT, ReferenceTracker, findVariable } = require("eslint-utils");
|
14
|
-
const { RegExpValidator, visitRegExpAST, RegExpParser } = require("regexpp");
|
13
|
+
const { CALL, CONSTRUCT, ReferenceTracker, findVariable } = require("@eslint-community/eslint-utils");
|
14
|
+
const { RegExpValidator, visitRegExpAST, RegExpParser } = require("@eslint-community/regexpp");
|
15
15
|
const { canTokensBeAdjacent } = require("./utils/ast-utils");
|
16
16
|
|
17
17
|
//------------------------------------------------------------------------------
|
package/lib/rules/wrap-iife.js
CHANGED
@@ -10,7 +10,7 @@
|
|
10
10
|
//------------------------------------------------------------------------------
|
11
11
|
|
12
12
|
const astUtils = require("./utils/ast-utils");
|
13
|
-
const eslintUtils = require("eslint-utils");
|
13
|
+
const eslintUtils = require("@eslint-community/eslint-utils");
|
14
14
|
|
15
15
|
//----------------------------------------------------------------------
|
16
16
|
// Helpers
|
@@ -9,7 +9,7 @@
|
|
9
9
|
//------------------------------------------------------------------------------
|
10
10
|
|
11
11
|
const
|
12
|
-
{ isCommentToken } = require("eslint-utils"),
|
12
|
+
{ isCommentToken } = require("@eslint-community/eslint-utils"),
|
13
13
|
TokenStore = require("./token-store"),
|
14
14
|
astUtils = require("../shared/ast-utils"),
|
15
15
|
Traverser = require("../shared/traverser");
|
@@ -9,7 +9,7 @@
|
|
9
9
|
//------------------------------------------------------------------------------
|
10
10
|
|
11
11
|
const assert = require("assert");
|
12
|
-
const { isCommentToken } = require("eslint-utils");
|
12
|
+
const { isCommentToken } = require("@eslint-community/eslint-utils");
|
13
13
|
const cursors = require("./cursors");
|
14
14
|
const ForwardTokenCursor = require("./forward-token-cursor");
|
15
15
|
const PaddedTokenCursor = require("./padded-token-cursor");
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "eslint",
|
3
|
-
"version": "8.
|
3
|
+
"version": "8.36.0",
|
4
4
|
"author": "Nicholas C. Zakas <nicholas+npm@nczconsulting.com>",
|
5
5
|
"description": "An AST-based pattern checker for JavaScript.",
|
6
6
|
"bin": {
|
@@ -60,8 +60,10 @@
|
|
60
60
|
"homepage": "https://eslint.org",
|
61
61
|
"bugs": "https://github.com/eslint/eslint/issues/",
|
62
62
|
"dependencies": {
|
63
|
-
"@eslint/
|
64
|
-
"@eslint/
|
63
|
+
"@eslint-community/eslint-utils": "^4.2.0",
|
64
|
+
"@eslint-community/regexpp": "^4.4.0",
|
65
|
+
"@eslint/eslintrc": "^2.0.1",
|
66
|
+
"@eslint/js": "8.36.0",
|
65
67
|
"@humanwhocodes/config-array": "^0.11.8",
|
66
68
|
"@humanwhocodes/module-importer": "^1.0.1",
|
67
69
|
"@nodelib/fs.walk": "^1.2.8",
|
@@ -72,9 +74,8 @@
|
|
72
74
|
"doctrine": "^3.0.0",
|
73
75
|
"escape-string-regexp": "^4.0.0",
|
74
76
|
"eslint-scope": "^7.1.1",
|
75
|
-
"eslint-utils": "^3.0.0",
|
76
77
|
"eslint-visitor-keys": "^3.3.0",
|
77
|
-
"espree": "^9.
|
78
|
+
"espree": "^9.5.0",
|
78
79
|
"esquery": "^1.4.2",
|
79
80
|
"esutils": "^2.0.2",
|
80
81
|
"fast-deep-equal": "^3.1.3",
|
@@ -96,7 +97,6 @@
|
|
96
97
|
"minimatch": "^3.1.2",
|
97
98
|
"natural-compare": "^1.4.0",
|
98
99
|
"optionator": "^0.9.1",
|
99
|
-
"regexpp": "^3.2.0",
|
100
100
|
"strip-ansi": "^6.0.1",
|
101
101
|
"strip-json-comments": "^3.1.0",
|
102
102
|
"text-table": "^0.2.0"
|