@typescript-eslint/experimental-utils 4.31.3-alpha.6 → 4.32.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/CHANGELOG.md +11 -0
- package/_ts3.4/dist/ast-utils/eslint-utils/PatternMatcher.d.ts +48 -0
- package/_ts3.4/dist/ast-utils/eslint-utils/ReferenceTracker.d.ts +76 -0
- package/_ts3.4/dist/ast-utils/eslint-utils/astUtilities.d.ts +76 -0
- package/_ts3.4/dist/ast-utils/eslint-utils/index.d.ts +6 -0
- package/_ts3.4/dist/ast-utils/eslint-utils/predicates.d.ts +32 -0
- package/_ts3.4/dist/ast-utils/eslint-utils/scopeAnalysis.d.ts +18 -0
- package/_ts3.4/dist/ast-utils/index.d.ts +4 -0
- package/_ts3.4/dist/ast-utils/misc.d.ts +8 -0
- package/_ts3.4/dist/ast-utils/predicates.d.ts +72 -0
- package/_ts3.4/dist/eslint-utils/InferTypesFromRule.d.ts +11 -0
- package/_ts3.4/dist/eslint-utils/RuleCreator.d.ts +13 -0
- package/_ts3.4/dist/eslint-utils/RuleTester.d.ts +18 -0
- package/_ts3.4/dist/eslint-utils/applyDefault.d.ts +10 -0
- package/_ts3.4/dist/eslint-utils/batchedSingleLineTests.d.ts +24 -0
- package/_ts3.4/dist/eslint-utils/deepMerge.d.ts +17 -0
- package/_ts3.4/dist/eslint-utils/getParserServices.d.ts +8 -0
- package/_ts3.4/dist/eslint-utils/index.d.ts +8 -0
- package/_ts3.4/dist/index.d.ts +8 -0
- package/_ts3.4/dist/json-schema.d.ts +2 -0
- package/_ts3.4/dist/ts-eslint/AST.d.ts +9 -0
- package/_ts3.4/dist/ts-eslint/CLIEngine.d.ts +143 -0
- package/_ts3.4/dist/ts-eslint/ESLint.d.ts +341 -0
- package/_ts3.4/dist/ts-eslint/Linter.d.ts +326 -0
- package/_ts3.4/dist/ts-eslint/ParserOptions.d.ts +2 -0
- package/_ts3.4/dist/ts-eslint/Rule.d.ts +381 -0
- package/_ts3.4/dist/ts-eslint/RuleTester.d.ts +148 -0
- package/_ts3.4/dist/ts-eslint/Scope.d.ts +44 -0
- package/_ts3.4/dist/ts-eslint/SourceCode.d.ts +352 -0
- package/_ts3.4/dist/ts-eslint/index.d.ts +10 -0
- package/_ts3.4/dist/ts-eslint-scope/Definition.d.ts +19 -0
- package/_ts3.4/dist/ts-eslint-scope/Options.d.ts +15 -0
- package/_ts3.4/dist/ts-eslint-scope/PatternVisitor.d.ts +25 -0
- package/_ts3.4/dist/ts-eslint-scope/Reference.d.ts +28 -0
- package/_ts3.4/dist/ts-eslint-scope/Referencer.d.ts +55 -0
- package/_ts3.4/dist/ts-eslint-scope/Scope.d.ts +103 -0
- package/_ts3.4/dist/ts-eslint-scope/ScopeManager.d.ts +50 -0
- package/_ts3.4/dist/ts-eslint-scope/Variable.d.ts +17 -0
- package/_ts3.4/dist/ts-eslint-scope/analyze.d.ts +16 -0
- package/_ts3.4/dist/ts-eslint-scope/index.d.ts +11 -0
- package/_ts3.4/dist/ts-estree.d.ts +3 -0
- package/dist/ast-utils/eslint-utils/astUtilities.d.ts +5 -11
- package/dist/ast-utils/eslint-utils/astUtilities.d.ts.map +1 -1
- package/dist/ast-utils/eslint-utils/astUtilities.js +0 -9
- package/dist/ast-utils/eslint-utils/astUtilities.js.map +1 -1
- package/package.json +5 -5
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { TSESTree } from '../ts-estree';
|
|
2
|
+
import { Reference } from './Reference';
|
|
3
|
+
import { Definition } from './Definition';
|
|
4
|
+
import { Scope } from './Scope';
|
|
5
|
+
interface Variable {
|
|
6
|
+
name: string;
|
|
7
|
+
identifiers: TSESTree.Identifier[];
|
|
8
|
+
references: Reference[];
|
|
9
|
+
defs: Definition[];
|
|
10
|
+
eslintUsed?: boolean;
|
|
11
|
+
stack?: unknown;
|
|
12
|
+
tainted?: boolean;
|
|
13
|
+
scope?: Scope;
|
|
14
|
+
}
|
|
15
|
+
declare const Variable: new () => Variable;
|
|
16
|
+
export { Variable };
|
|
17
|
+
//# sourceMappingURL=Variable.d.ts.map
|
|
@@ -0,0 +1,16 @@
|
|
|
1
|
+
import { EcmaVersion } from '../ts-eslint';
|
|
2
|
+
import { TSESTree } from '../ts-estree';
|
|
3
|
+
import { ScopeManager } from './ScopeManager';
|
|
4
|
+
interface AnalysisOptions {
|
|
5
|
+
optimistic?: boolean;
|
|
6
|
+
directive?: boolean;
|
|
7
|
+
ignoreEval?: boolean;
|
|
8
|
+
nodejsScope?: boolean;
|
|
9
|
+
impliedStrict?: boolean;
|
|
10
|
+
fallback?: string | ((node: TSESTree.Node) => string[]);
|
|
11
|
+
sourceType?: 'script' | 'module';
|
|
12
|
+
ecmaVersion?: EcmaVersion;
|
|
13
|
+
}
|
|
14
|
+
declare const analyze: (ast: TSESTree.Node, options?: AnalysisOptions | undefined) => ScopeManager;
|
|
15
|
+
export { analyze, AnalysisOptions };
|
|
16
|
+
//# sourceMappingURL=analyze.d.ts.map
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
export * from './analyze';
|
|
2
|
+
export * from './Definition';
|
|
3
|
+
export * from './Options';
|
|
4
|
+
export * from './PatternVisitor';
|
|
5
|
+
export * from './Reference';
|
|
6
|
+
export * from './Referencer';
|
|
7
|
+
export * from './Scope';
|
|
8
|
+
export * from './ScopeManager';
|
|
9
|
+
export * from './Variable';
|
|
10
|
+
export declare const version: string;
|
|
11
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { TSESTree } from '../../ts-estree';
|
|
2
1
|
import * as TSESLint from '../../ts-eslint';
|
|
2
|
+
import { TSESTree } from '../../ts-estree';
|
|
3
3
|
/**
|
|
4
4
|
* Get the proper location of a given function node to report.
|
|
5
5
|
*
|
|
@@ -68,15 +68,9 @@ declare const hasSideEffect: (node: TSESTree.Node, sourceCode: TSESLint.SourceCo
|
|
|
68
68
|
considerGetters?: boolean | undefined;
|
|
69
69
|
considerImplicitTypeConversion?: boolean | undefined;
|
|
70
70
|
} | undefined) => boolean;
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
* @see {@link https://eslint-utils.mysticatea.dev/api/ast-utils.html#isparenthesized}
|
|
76
|
-
* @returns `true` if the node is parenthesized.
|
|
77
|
-
* If `times` was given, it returns `true` only if the node is parenthesized the `times` times.
|
|
78
|
-
* For example, `isParenthesized(2, node, sourceCode)` returns true for `((foo))`, but not for `(foo)`.
|
|
79
|
-
*/
|
|
80
|
-
declare const isParenthesized: (node: TSESTree.Node, sourceCode: TSESLint.SourceCode) => boolean;
|
|
71
|
+
declare const isParenthesized: {
|
|
72
|
+
(node: TSESTree.Node, sourceCode: TSESLint.SourceCode): boolean;
|
|
73
|
+
(times: number, node: TSESTree.Node, sourceCode: TSESLint.SourceCode): boolean;
|
|
74
|
+
};
|
|
81
75
|
export { getFunctionHeadLocation, getFunctionNameWithKind, getPropertyName, getStaticValue, getStringIfConstant, hasSideEffect, isParenthesized, };
|
|
82
76
|
//# sourceMappingURL=astUtilities.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"astUtilities.d.ts","sourceRoot":"","sources":["../../../src/ast-utils/eslint-utils/astUtilities.ts"],"names":[],"mappings":"AACA,OAAO,
|
|
1
|
+
{"version":3,"file":"astUtilities.d.ts","sourceRoot":"","sources":["../../../src/ast-utils/eslint-utils/astUtilities.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,QAAQ,MAAM,iBAAiB,CAAC;AAC5C,OAAO,EAAE,QAAQ,EAAE,MAAM,iBAAiB,CAAC;AAE3C;;;;GAIG;AACH,QAAA,MAAM,uBAAuB,SAEvB,SAAS,mBAAmB,GAC5B,SAAS,kBAAkB,GAC3B,SAAS,uBAAuB,cACxB,SAAS,UAAU,KAC5B,SAAS,cAAc,CAAC;AAE7B;;;;GAIG;AACH,QAAA,MAAM,uBAAuB,SAEvB,SAAS,mBAAmB,GAC5B,SAAS,kBAAkB,GAC3B,SAAS,uBAAuB,KACjC,MAAM,CAAC;AAEZ;;;;;;GAMG;AACH,QAAA,MAAM,eAAe,SAEf,SAAS,gBAAgB,GACzB,SAAS,QAAQ,GACjB,SAAS,gBAAgB,mGAE1B,MAAM,GAAG,IAAI,CAAC;AAEnB;;;;;;;;;;GAUG;AACH,QAAA,MAAM,cAAc,SACZ,SAAS,IAAI,mGAEhB;IAAE,KAAK,EAAE,OAAO,CAAA;CAAE,GAAG,IAAI,CAAC;AAE/B;;;;;GAKG;AACH,QAAA,MAAM,mBAAmB,SACjB,SAAS,IAAI,mGAEhB,MAAM,GAAG,IAAI,CAAC;AAEnB;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,QAAA,MAAM,aAAa,SACX,SAAS,IAAI,cACP,SAAS,UAAU;;;kBAK5B,OAAO,CAAC;AAEb,QAAA,MAAM,eAAe;WAUZ,SAAS,IAAI,cAAc,SAAS,UAAU,GAAG,OAAO;YAEtD,MAAM,QACP,SAAS,IAAI,cACP,SAAS,UAAU,GAC9B,OAAO;CACX,CAAC;AAEF,OAAO,EACL,uBAAuB,EACvB,uBAAuB,EACvB,eAAe,EACf,cAAc,EACd,mBAAmB,EACnB,aAAa,EACb,eAAe,GAChB,CAAC"}
|
|
@@ -90,15 +90,6 @@ exports.getStringIfConstant = getStringIfConstant;
|
|
|
90
90
|
*/
|
|
91
91
|
const hasSideEffect = eslintUtils.hasSideEffect;
|
|
92
92
|
exports.hasSideEffect = hasSideEffect;
|
|
93
|
-
/**
|
|
94
|
-
* Check whether a given node is parenthesized or not.
|
|
95
|
-
* This function detects it correctly even if it's parenthesized by specific syntax.
|
|
96
|
-
*
|
|
97
|
-
* @see {@link https://eslint-utils.mysticatea.dev/api/ast-utils.html#isparenthesized}
|
|
98
|
-
* @returns `true` if the node is parenthesized.
|
|
99
|
-
* If `times` was given, it returns `true` only if the node is parenthesized the `times` times.
|
|
100
|
-
* For example, `isParenthesized(2, node, sourceCode)` returns true for `((foo))`, but not for `(foo)`.
|
|
101
|
-
*/
|
|
102
93
|
const isParenthesized = eslintUtils.isParenthesized;
|
|
103
94
|
exports.isParenthesized = isParenthesized;
|
|
104
95
|
//# sourceMappingURL=astUtilities.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"astUtilities.js","sourceRoot":"","sources":["../../../src/ast-utils/eslint-utils/astUtilities.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAAA,0DAA4C;AAI5C;;;;GAIG;AACH,MAAM,uBAAuB,GAAG,WAAW,CAAC,uBAMhB,CAAC;
|
|
1
|
+
{"version":3,"file":"astUtilities.js","sourceRoot":"","sources":["../../../src/ast-utils/eslint-utils/astUtilities.ts"],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;AAAA,0DAA4C;AAI5C;;;;GAIG;AACH,MAAM,uBAAuB,GAAG,WAAW,CAAC,uBAMhB,CAAC;AA2G3B,0DAAuB;AAzGzB;;;;GAIG;AACH,MAAM,uBAAuB,GAAG,WAAW,CAAC,uBAKjC,CAAC;AAgGV,0DAAuB;AA9FzB;;;;;;GAMG;AACH,MAAM,eAAe,GAAG,WAAW,CAAC,eAMlB,CAAC;AAkFjB,0CAAe;AAhFjB;;;;;;;;;;GAUG;AACH,MAAM,cAAc,GAAG,WAAW,CAAC,cAGL,CAAC;AAmE7B,wCAAc;AAjEhB;;;;;GAKG;AACH,MAAM,mBAAmB,GAAG,WAAW,CAAC,mBAGtB,CAAC;AAyDjB,kDAAmB;AAvDrB;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,MAAM,aAAa,GAAG,WAAW,CAAC,aAOtB,CAAC;AA0BX,sCAAa;AAxBf,MAAM,eAAe,GAAG,WAAW,CAAC,eAgBnC,CAAC;AASA,0CAAe"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@typescript-eslint/experimental-utils",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.32.0",
|
|
4
4
|
"description": "(Experimental) Utilities for working with TypeScript + ESLint together",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"eslint",
|
|
@@ -40,9 +40,9 @@
|
|
|
40
40
|
},
|
|
41
41
|
"dependencies": {
|
|
42
42
|
"@types/json-schema": "^7.0.7",
|
|
43
|
-
"@typescript-eslint/scope-manager": "4.
|
|
44
|
-
"@typescript-eslint/types": "4.
|
|
45
|
-
"@typescript-eslint/typescript-estree": "4.
|
|
43
|
+
"@typescript-eslint/scope-manager": "4.32.0",
|
|
44
|
+
"@typescript-eslint/types": "4.32.0",
|
|
45
|
+
"@typescript-eslint/typescript-estree": "4.32.0",
|
|
46
46
|
"eslint-scope": "^5.1.1",
|
|
47
47
|
"eslint-utils": "^3.0.0"
|
|
48
48
|
},
|
|
@@ -63,5 +63,5 @@
|
|
|
63
63
|
]
|
|
64
64
|
}
|
|
65
65
|
},
|
|
66
|
-
"gitHead": "
|
|
66
|
+
"gitHead": "02c6ff3c5a558f9308d7166d524156dc12e32759"
|
|
67
67
|
}
|