UNPKG

28.4 kBTypeScriptView Raw
1// Generated by dts-bundle v0.7.3
2// Dependencies for this module:
3// ../eslint-scope
4// ../@typescript-eslint/utils
5// ../eslint-visitor-keys
6
7declare module 'vue-eslint-parser' {
8 import * as AST from "vue-eslint-parser/ast";
9 export function parseForESLint(code: string, parserOptions: any): AST.ESLintExtendedProgram;
10 export function parse(code: string, options: any): AST.ESLintProgram;
11 export { AST };
12 export const meta: {
13 name: string;
14 version: string | undefined;
15 };
16}
17
18declare module 'vue-eslint-parser/ast' {
19 export * from "vue-eslint-parser/ast/errors";
20 export * from "vue-eslint-parser/ast/locations";
21 export * from "vue-eslint-parser/ast/nodes";
22 export * from "vue-eslint-parser/ast/tokens";
23 export * from "vue-eslint-parser/ast/traverse";
24}
25
26declare module 'vue-eslint-parser/ast/errors' {
27 export class ParseError extends SyntaxError {
28 code?: ErrorCode;
29 index: number;
30 lineNumber: number;
31 column: number;
32 static fromCode(code: ErrorCode, offset: number, line: number, column: number): ParseError;
33 static normalize(x: any): ParseError | null;
34 constructor(message: string, code: ErrorCode | undefined, offset: number, line: number, column: number);
35 static isParseError(x: any): x is ParseError;
36 }
37 export type ErrorCode = "abrupt-closing-of-empty-comment" | "absence-of-digits-in-numeric-character-reference" | "cdata-in-html-content" | "character-reference-outside-unicode-range" | "control-character-in-input-stream" | "control-character-reference" | "eof-before-tag-name" | "eof-in-cdata" | "eof-in-comment" | "eof-in-tag" | "incorrectly-closed-comment" | "incorrectly-opened-comment" | "invalid-first-character-of-tag-name" | "missing-attribute-value" | "missing-end-tag-name" | "missing-semicolon-after-character-reference" | "missing-whitespace-between-attributes" | "nested-comment" | "noncharacter-character-reference" | "noncharacter-in-input-stream" | "null-character-reference" | "surrogate-character-reference" | "surrogate-in-input-stream" | "unexpected-character-in-attribute-name" | "unexpected-character-in-unquoted-attribute-value" | "unexpected-equals-sign-before-attribute-name" | "unexpected-null-character" | "unexpected-question-mark-instead-of-tag-name" | "unexpected-solidus-in-tag" | "unknown-named-character-reference" | "end-tag-with-attributes" | "duplicate-attribute" | "end-tag-with-trailing-solidus" | "non-void-html-element-start-tag-with-trailing-solidus" | "x-invalid-end-tag" | "x-invalid-namespace" | "x-missing-interpolation-end";
38}
39
40declare module 'vue-eslint-parser/ast/locations' {
41 export interface Location {
42 line: number;
43 column: number;
44 }
45 export interface LocationRange {
46 start: Location;
47 end: Location;
48 }
49 export type Offset = number;
50 export type OffsetRange = [Offset, Offset];
51 export interface HasLocation {
52 range: OffsetRange;
53 loc: LocationRange;
54 start?: number;
55 end?: number;
56 }
57}
58
59declare module 'vue-eslint-parser/ast/nodes' {
60 import type { ScopeManager } from "eslint-scope";
61 import type { ParseError } from "vue-eslint-parser/ast/errors";
62 import type { HasLocation } from "vue-eslint-parser/ast/locations";
63 import type { Token } from "vue-eslint-parser/ast/tokens";
64 import type { TSESTree } from "@typescript-eslint/utils";
65 export interface HasParent {
66 parent?: Node | null;
67 }
68 export type Node = ESLintNode | VNode | VForExpression | VOnExpression | VSlotScopeExpression | VGenericExpression | VFilterSequenceExpression | VFilter;
69 export type ESLintNode = ESLintIdentifier | ESLintLiteral | ESLintProgram | ESLintSwitchCase | ESLintCatchClause | ESLintVariableDeclarator | ESLintStatement | ESLintExpression | ESLintProperty | ESLintAssignmentProperty | ESLintSuper | ESLintTemplateElement | ESLintSpreadElement | ESLintPattern | ESLintClassBody | ESLintMethodDefinition | ESLintPropertyDefinition | ESLintStaticBlock | ESLintPrivateIdentifier | ESLintModuleDeclaration | ESLintModuleSpecifier | ESLintImportExpression | ESLintLegacyRestProperty;
70 export interface ESLintExtendedProgram {
71 ast: ESLintProgram;
72 services?: {};
73 visitorKeys?: {
74 [type: string]: string[];
75 };
76 scopeManager?: ScopeManager;
77 }
78 export interface ESLintProgram extends HasLocation, HasParent {
79 type: "Program";
80 sourceType: "script" | "module";
81 body: (ESLintStatement | ESLintModuleDeclaration)[];
82 templateBody?: VElement & HasConcreteInfo;
83 tokens?: Token[];
84 comments?: Token[];
85 errors?: ParseError[];
86 }
87 export type ESLintStatement = ESLintExpressionStatement | ESLintBlockStatement | ESLintEmptyStatement | ESLintDebuggerStatement | ESLintWithStatement | ESLintReturnStatement | ESLintLabeledStatement | ESLintBreakStatement | ESLintContinueStatement | ESLintIfStatement | ESLintSwitchStatement | ESLintThrowStatement | ESLintTryStatement | ESLintWhileStatement | ESLintDoWhileStatement | ESLintForStatement | ESLintForInStatement | ESLintForOfStatement | ESLintDeclaration;
88 export interface ESLintEmptyStatement extends HasLocation, HasParent {
89 type: "EmptyStatement";
90 }
91 export interface ESLintBlockStatement extends HasLocation, HasParent {
92 type: "BlockStatement";
93 body: ESLintStatement[];
94 }
95 export interface ESLintExpressionStatement extends HasLocation, HasParent {
96 type: "ExpressionStatement";
97 expression: ESLintExpression;
98 }
99 export interface ESLintIfStatement extends HasLocation, HasParent {
100 type: "IfStatement";
101 test: ESLintExpression;
102 consequent: ESLintStatement;
103 alternate: ESLintStatement | null;
104 }
105 export interface ESLintSwitchStatement extends HasLocation, HasParent {
106 type: "SwitchStatement";
107 discriminant: ESLintExpression;
108 cases: ESLintSwitchCase[];
109 }
110 export interface ESLintSwitchCase extends HasLocation, HasParent {
111 type: "SwitchCase";
112 test: ESLintExpression | null;
113 consequent: ESLintStatement[];
114 }
115 export interface ESLintWhileStatement extends HasLocation, HasParent {
116 type: "WhileStatement";
117 test: ESLintExpression;
118 body: ESLintStatement;
119 }
120 export interface ESLintDoWhileStatement extends HasLocation, HasParent {
121 type: "DoWhileStatement";
122 body: ESLintStatement;
123 test: ESLintExpression;
124 }
125 export interface ESLintForStatement extends HasLocation, HasParent {
126 type: "ForStatement";
127 init: ESLintVariableDeclaration | ESLintExpression | null;
128 test: ESLintExpression | null;
129 update: ESLintExpression | null;
130 body: ESLintStatement;
131 }
132 export interface ESLintForInStatement extends HasLocation, HasParent {
133 type: "ForInStatement";
134 left: ESLintVariableDeclaration | ESLintPattern;
135 right: ESLintExpression;
136 body: ESLintStatement;
137 }
138 export interface ESLintForOfStatement extends HasLocation, HasParent {
139 type: "ForOfStatement";
140 left: ESLintVariableDeclaration | ESLintPattern;
141 right: ESLintExpression;
142 body: ESLintStatement;
143 await: boolean;
144 }
145 export interface ESLintLabeledStatement extends HasLocation, HasParent {
146 type: "LabeledStatement";
147 label: ESLintIdentifier;
148 body: ESLintStatement;
149 }
150 export interface ESLintBreakStatement extends HasLocation, HasParent {
151 type: "BreakStatement";
152 label: ESLintIdentifier | null;
153 }
154 export interface ESLintContinueStatement extends HasLocation, HasParent {
155 type: "ContinueStatement";
156 label: ESLintIdentifier | null;
157 }
158 export interface ESLintReturnStatement extends HasLocation, HasParent {
159 type: "ReturnStatement";
160 argument: ESLintExpression | null;
161 }
162 export interface ESLintThrowStatement extends HasLocation, HasParent {
163 type: "ThrowStatement";
164 argument: ESLintExpression;
165 }
166 export interface ESLintTryStatement extends HasLocation, HasParent {
167 type: "TryStatement";
168 block: ESLintBlockStatement;
169 handler: ESLintCatchClause | null;
170 finalizer: ESLintBlockStatement | null;
171 }
172 export interface ESLintCatchClause extends HasLocation, HasParent {
173 type: "CatchClause";
174 param: ESLintPattern | null;
175 body: ESLintBlockStatement;
176 }
177 export interface ESLintWithStatement extends HasLocation, HasParent {
178 type: "WithStatement";
179 object: ESLintExpression;
180 body: ESLintStatement;
181 }
182 export interface ESLintDebuggerStatement extends HasLocation, HasParent {
183 type: "DebuggerStatement";
184 }
185 export type ESLintDeclaration = ESLintFunctionDeclaration | ESLintVariableDeclaration | ESLintClassDeclaration;
186 export interface ESLintFunctionDeclaration extends HasLocation, HasParent {
187 type: "FunctionDeclaration";
188 async: boolean;
189 generator: boolean;
190 id: ESLintIdentifier | null;
191 params: ESLintPattern[];
192 body: ESLintBlockStatement;
193 }
194 export interface ESLintVariableDeclaration extends HasLocation, HasParent {
195 type: "VariableDeclaration";
196 kind: "var" | "let" | "const";
197 declarations: ESLintVariableDeclarator[];
198 }
199 export interface ESLintVariableDeclarator extends HasLocation, HasParent {
200 type: "VariableDeclarator";
201 id: ESLintPattern;
202 init: ESLintExpression | null;
203 }
204 export interface ESLintClassDeclaration extends HasLocation, HasParent {
205 type: "ClassDeclaration";
206 id: ESLintIdentifier | null;
207 superClass: ESLintExpression | null;
208 body: ESLintClassBody;
209 }
210 export interface ESLintClassBody extends HasLocation, HasParent {
211 type: "ClassBody";
212 body: (ESLintMethodDefinition | ESLintPropertyDefinition | ESLintStaticBlock)[];
213 }
214 export interface ESLintMethodDefinition extends HasLocation, HasParent {
215 type: "MethodDefinition";
216 kind: "constructor" | "method" | "get" | "set";
217 computed: boolean;
218 static: boolean;
219 key: ESLintExpression | ESLintPrivateIdentifier;
220 value: ESLintFunctionExpression;
221 }
222 export interface ESLintPropertyDefinition extends HasLocation, HasParent {
223 type: "PropertyDefinition";
224 computed: boolean;
225 static: boolean;
226 key: ESLintExpression | ESLintPrivateIdentifier;
227 value: ESLintExpression | null;
228 }
229 export interface ESLintStaticBlock extends HasLocation, HasParent, Omit<ESLintBlockStatement, "type"> {
230 type: "StaticBlock";
231 body: ESLintStatement[];
232 }
233 export interface ESLintPrivateIdentifier extends HasLocation, HasParent {
234 type: "PrivateIdentifier";
235 name: string;
236 }
237 export type ESLintModuleDeclaration = ESLintImportDeclaration | ESLintExportNamedDeclaration | ESLintExportDefaultDeclaration | ESLintExportAllDeclaration;
238 export type ESLintModuleSpecifier = ESLintImportSpecifier | ESLintImportDefaultSpecifier | ESLintImportNamespaceSpecifier | ESLintExportSpecifier;
239 export interface ESLintImportDeclaration extends HasLocation, HasParent {
240 type: "ImportDeclaration";
241 specifiers: (ESLintImportSpecifier | ESLintImportDefaultSpecifier | ESLintImportNamespaceSpecifier)[];
242 source: ESLintLiteral;
243 }
244 export interface ESLintImportSpecifier extends HasLocation, HasParent {
245 type: "ImportSpecifier";
246 imported: ESLintIdentifier | ESLintStringLiteral;
247 local: ESLintIdentifier;
248 }
249 export interface ESLintImportDefaultSpecifier extends HasLocation, HasParent {
250 type: "ImportDefaultSpecifier";
251 local: ESLintIdentifier;
252 }
253 export interface ESLintImportNamespaceSpecifier extends HasLocation, HasParent {
254 type: "ImportNamespaceSpecifier";
255 local: ESLintIdentifier;
256 }
257 export interface ESLintImportExpression extends HasLocation, HasParent {
258 type: "ImportExpression";
259 source: ESLintExpression;
260 }
261 export interface ESLintExportNamedDeclaration extends HasLocation, HasParent {
262 type: "ExportNamedDeclaration";
263 declaration?: ESLintDeclaration | null;
264 specifiers: ESLintExportSpecifier[];
265 source?: ESLintLiteral | null;
266 }
267 export interface ESLintExportSpecifier extends HasLocation, HasParent {
268 type: "ExportSpecifier";
269 local: ESLintIdentifier | ESLintStringLiteral;
270 exported: ESLintIdentifier | ESLintStringLiteral;
271 }
272 export interface ESLintExportDefaultDeclaration extends HasLocation, HasParent {
273 type: "ExportDefaultDeclaration";
274 declaration: ESLintDeclaration | ESLintExpression;
275 }
276 export interface ESLintExportAllDeclaration extends HasLocation, HasParent {
277 type: "ExportAllDeclaration";
278 exported: ESLintIdentifier | ESLintStringLiteral | null;
279 source: ESLintLiteral;
280 }
281 export type ESLintExpression = ESLintThisExpression | ESLintArrayExpression | ESLintObjectExpression | ESLintFunctionExpression | ESLintArrowFunctionExpression | ESLintYieldExpression | ESLintLiteral | ESLintUnaryExpression | ESLintUpdateExpression | ESLintBinaryExpression | ESLintAssignmentExpression | ESLintLogicalExpression | ESLintMemberExpression | ESLintConditionalExpression | ESLintCallExpression | ESLintNewExpression | ESLintSequenceExpression | ESLintTemplateLiteral | ESLintTaggedTemplateExpression | ESLintClassExpression | ESLintMetaProperty | ESLintIdentifier | ESLintAwaitExpression | ESLintChainExpression;
282 export interface ESLintIdentifier extends HasLocation, HasParent {
283 type: "Identifier";
284 name: string;
285 }
286 interface ESLintLiteralBase extends HasLocation, HasParent {
287 type: "Literal";
288 value: string | boolean | null | number | RegExp | bigint;
289 raw: string;
290 regex?: {
291 pattern: string;
292 flags: string;
293 };
294 bigint?: string;
295 }
296 export interface ESLintStringLiteral extends ESLintLiteralBase {
297 value: string;
298 regex?: undefined;
299 bigint?: undefined;
300 }
301 export interface ESLintBooleanLiteral extends ESLintLiteralBase {
302 value: boolean;
303 regex?: undefined;
304 bigint?: undefined;
305 }
306 export interface ESLintNullLiteral extends ESLintLiteralBase {
307 value: null;
308 regex?: undefined;
309 bigint?: undefined;
310 }
311 export interface ESLintNumberLiteral extends ESLintLiteralBase {
312 value: number;
313 regex?: undefined;
314 bigint?: undefined;
315 }
316 export interface ESLintRegExpLiteral extends ESLintLiteralBase {
317 value: null | RegExp;
318 regex: {
319 pattern: string;
320 flags: string;
321 };
322 bigint?: undefined;
323 }
324 export interface ESLintBigIntLiteral extends ESLintLiteralBase {
325 value: null | bigint;
326 regex?: undefined;
327 bigint: string;
328 }
329 export type ESLintLiteral = ESLintStringLiteral | ESLintBooleanLiteral | ESLintNullLiteral | ESLintNumberLiteral | ESLintRegExpLiteral | ESLintBigIntLiteral;
330 export interface ESLintThisExpression extends HasLocation, HasParent {
331 type: "ThisExpression";
332 }
333 export interface ESLintArrayExpression extends HasLocation, HasParent {
334 type: "ArrayExpression";
335 elements: (ESLintExpression | ESLintSpreadElement)[];
336 }
337 export interface ESLintObjectExpression extends HasLocation, HasParent {
338 type: "ObjectExpression";
339 properties: (ESLintProperty | ESLintSpreadElement | ESLintLegacySpreadProperty)[];
340 }
341 export interface ESLintProperty extends HasLocation, HasParent {
342 type: "Property";
343 kind: "init" | "get" | "set";
344 method: boolean;
345 shorthand: boolean;
346 computed: boolean;
347 key: ESLintExpression;
348 value: ESLintExpression | ESLintPattern;
349 }
350 export interface ESLintFunctionExpression extends HasLocation, HasParent {
351 type: "FunctionExpression";
352 async: boolean;
353 generator: boolean;
354 id: ESLintIdentifier | null;
355 params: ESLintPattern[];
356 body: ESLintBlockStatement;
357 }
358 export interface ESLintArrowFunctionExpression extends HasLocation, HasParent {
359 type: "ArrowFunctionExpression";
360 async: boolean;
361 generator: boolean;
362 id: ESLintIdentifier | null;
363 params: ESLintPattern[];
364 body: ESLintBlockStatement | ESLintExpression;
365 }
366 export interface ESLintSequenceExpression extends HasLocation, HasParent {
367 type: "SequenceExpression";
368 expressions: ESLintExpression[];
369 }
370 export interface ESLintUnaryExpression extends HasLocation, HasParent {
371 type: "UnaryExpression";
372 operator: "-" | "+" | "!" | "~" | "typeof" | "void" | "delete";
373 prefix: boolean;
374 argument: ESLintExpression;
375 }
376 export interface ESLintBinaryExpression extends HasLocation, HasParent {
377 type: "BinaryExpression";
378 operator: "==" | "!=" | "===" | "!==" | "<" | "<=" | ">" | ">=" | "<<" | ">>" | ">>>" | "+" | "-" | "*" | "/" | "%" | "**" | "|" | "^" | "&" | "in" | "instanceof";
379 left: ESLintExpression | ESLintPrivateIdentifier;
380 right: ESLintExpression;
381 }
382 export interface ESLintAssignmentExpression extends HasLocation, HasParent {
383 type: "AssignmentExpression";
384 operator: "=" | "+=" | "-=" | "*=" | "/=" | "%=" | "**=" | "<<=" | ">>=" | ">>>=" | "|=" | "^=" | "&=" | "||=" | "&&=" | "??=";
385 left: ESLintPattern;
386 right: ESLintExpression;
387 }
388 export interface ESLintUpdateExpression extends HasLocation, HasParent {
389 type: "UpdateExpression";
390 operator: "++" | "--";
391 argument: ESLintExpression;
392 prefix: boolean;
393 }
394 export interface ESLintLogicalExpression extends HasLocation, HasParent {
395 type: "LogicalExpression";
396 operator: "||" | "&&" | "??";
397 left: ESLintExpression;
398 right: ESLintExpression;
399 }
400 export interface ESLintConditionalExpression extends HasLocation, HasParent {
401 type: "ConditionalExpression";
402 test: ESLintExpression;
403 alternate: ESLintExpression;
404 consequent: ESLintExpression;
405 }
406 export interface ESLintCallExpression extends HasLocation, HasParent {
407 type: "CallExpression";
408 optional: boolean;
409 callee: ESLintExpression | ESLintSuper;
410 arguments: (ESLintExpression | ESLintSpreadElement)[];
411 }
412 export interface ESLintSuper extends HasLocation, HasParent {
413 type: "Super";
414 }
415 export interface ESLintNewExpression extends HasLocation, HasParent {
416 type: "NewExpression";
417 callee: ESLintExpression;
418 arguments: (ESLintExpression | ESLintSpreadElement)[];
419 }
420 export interface ESLintMemberExpression extends HasLocation, HasParent {
421 type: "MemberExpression";
422 optional: boolean;
423 computed: boolean;
424 object: ESLintExpression | ESLintSuper;
425 property: ESLintExpression | ESLintPrivateIdentifier;
426 }
427 export interface ESLintYieldExpression extends HasLocation, HasParent {
428 type: "YieldExpression";
429 delegate: boolean;
430 argument: ESLintExpression | null;
431 }
432 export interface ESLintAwaitExpression extends HasLocation, HasParent {
433 type: "AwaitExpression";
434 argument: ESLintExpression;
435 }
436 export interface ESLintTemplateLiteral extends HasLocation, HasParent {
437 type: "TemplateLiteral";
438 quasis: ESLintTemplateElement[];
439 expressions: ESLintExpression[];
440 }
441 export interface ESLintTaggedTemplateExpression extends HasLocation, HasParent {
442 type: "TaggedTemplateExpression";
443 tag: ESLintExpression;
444 quasi: ESLintTemplateLiteral;
445 }
446 export interface ESLintTemplateElement extends HasLocation, HasParent {
447 type: "TemplateElement";
448 tail: boolean;
449 value: {
450 cooked: string | null;
451 raw: string;
452 };
453 }
454 export interface ESLintClassExpression extends HasLocation, HasParent {
455 type: "ClassExpression";
456 id: ESLintIdentifier | null;
457 superClass: ESLintExpression | null;
458 body: ESLintClassBody;
459 }
460 export interface ESLintMetaProperty extends HasLocation, HasParent {
461 type: "MetaProperty";
462 meta: ESLintIdentifier;
463 property: ESLintIdentifier;
464 }
465 export type ESLintPattern = ESLintIdentifier | ESLintObjectPattern | ESLintArrayPattern | ESLintRestElement | ESLintAssignmentPattern | ESLintMemberExpression | ESLintLegacyRestProperty;
466 export interface ESLintObjectPattern extends HasLocation, HasParent {
467 type: "ObjectPattern";
468 properties: (ESLintAssignmentProperty | ESLintRestElement | ESLintLegacyRestProperty)[];
469 }
470 export interface ESLintAssignmentProperty extends ESLintProperty {
471 value: ESLintPattern;
472 kind: "init";
473 method: false;
474 }
475 export interface ESLintArrayPattern extends HasLocation, HasParent {
476 type: "ArrayPattern";
477 elements: ESLintPattern[];
478 }
479 export interface ESLintRestElement extends HasLocation, HasParent {
480 type: "RestElement";
481 argument: ESLintPattern;
482 }
483 export interface ESLintSpreadElement extends HasLocation, HasParent {
484 type: "SpreadElement";
485 argument: ESLintExpression;
486 }
487 export interface ESLintAssignmentPattern extends HasLocation, HasParent {
488 type: "AssignmentPattern";
489 left: ESLintPattern;
490 right: ESLintExpression;
491 }
492 export type ESLintChainElement = ESLintCallExpression | ESLintMemberExpression;
493 export interface ESLintChainExpression extends HasLocation, HasParent {
494 type: "ChainExpression";
495 expression: ESLintChainElement;
496 }
497 export interface ESLintLegacyRestProperty extends HasLocation, HasParent {
498 type: "RestProperty" | "ExperimentalRestProperty";
499 argument: ESLintPattern;
500 }
501 export interface ESLintLegacySpreadProperty extends HasLocation, HasParent {
502 type: "SpreadProperty" | "ExperimentalSpreadProperty";
503 argument: ESLintExpression;
504 }
505 export const NS: Readonly<{
506 HTML: "http://www.w3.org/1999/xhtml";
507 MathML: "http://www.w3.org/1998/Math/MathML";
508 SVG: "http://www.w3.org/2000/svg";
509 XLink: "http://www.w3.org/1999/xlink";
510 XML: "http://www.w3.org/XML/1998/namespace";
511 XMLNS: "http://www.w3.org/2000/xmlns/";
512 }>;
513 export type Namespace = typeof NS.HTML | typeof NS.MathML | typeof NS.SVG | typeof NS.XLink | typeof NS.XML | typeof NS.XMLNS;
514 export interface Variable {
515 id: ESLintIdentifier;
516 kind: "v-for" | "scope" | "generic";
517 references: Reference[];
518 }
519 export interface Reference {
520 id: ESLintIdentifier;
521 mode: "rw" | "r" | "w";
522 variable: Variable | null;
523 isValueReference?: boolean;
524 isTypeReference?: boolean;
525 }
526 export interface VForExpression extends HasLocation, HasParent {
527 type: "VForExpression";
528 parent: VExpressionContainer;
529 left: ESLintPattern[];
530 right: ESLintExpression;
531 }
532 export interface VOnExpression extends HasLocation, HasParent {
533 type: "VOnExpression";
534 parent: VExpressionContainer;
535 body: ESLintStatement[];
536 }
537 export interface VSlotScopeExpression extends HasLocation, HasParent {
538 type: "VSlotScopeExpression";
539 parent: VExpressionContainer;
540 params: ESLintPattern[];
541 }
542 export interface VGenericExpression extends HasLocation, HasParent {
543 type: "VGenericExpression";
544 parent: VExpressionContainer;
545 params: TSESTree.TSTypeParameterDeclaration["params"];
546 rawParams: string[];
547 }
548 export interface VFilterSequenceExpression extends HasLocation, HasParent {
549 type: "VFilterSequenceExpression";
550 parent: VExpressionContainer;
551 expression: ESLintExpression;
552 filters: VFilter[];
553 }
554 export interface VFilter extends HasLocation, HasParent {
555 type: "VFilter";
556 parent: VFilterSequenceExpression;
557 callee: ESLintIdentifier;
558 arguments: (ESLintExpression | ESLintSpreadElement)[];
559 }
560 export type VNode = VAttribute | VDirective | VDirectiveKey | VDocumentFragment | VElement | VEndTag | VExpressionContainer | VIdentifier | VLiteral | VStartTag | VText;
561 export interface VText extends HasLocation, HasParent {
562 type: "VText";
563 parent: VDocumentFragment | VElement;
564 value: string;
565 }
566 export interface VExpressionContainer extends HasLocation, HasParent {
567 type: "VExpressionContainer";
568 parent: VDocumentFragment | VElement | VDirective | VDirectiveKey;
569 expression: ESLintExpression | VFilterSequenceExpression | VForExpression | VOnExpression | VSlotScopeExpression | VGenericExpression | null;
570 references: Reference[];
571 }
572 export interface VIdentifier extends HasLocation, HasParent {
573 type: "VIdentifier";
574 parent: VAttribute | VDirectiveKey;
575 name: string;
576 rawName: string;
577 }
578 export interface VDirectiveKey extends HasLocation, HasParent {
579 type: "VDirectiveKey";
580 parent: VDirective;
581 name: VIdentifier;
582 argument: VExpressionContainer | VIdentifier | null;
583 modifiers: VIdentifier[];
584 }
585 export interface VLiteral extends HasLocation, HasParent {
586 type: "VLiteral";
587 parent: VAttribute;
588 value: string;
589 }
590 export interface VAttribute extends HasLocation, HasParent {
591 type: "VAttribute";
592 parent: VStartTag;
593 directive: false;
594 key: VIdentifier;
595 value: VLiteral | null;
596 }
597 export interface VDirective extends HasLocation, HasParent {
598 type: "VAttribute";
599 parent: VStartTag;
600 directive: true;
601 key: VDirectiveKey;
602 value: VExpressionContainer | null;
603 }
604 export interface VStartTag extends HasLocation, HasParent {
605 type: "VStartTag";
606 parent: VElement;
607 selfClosing: boolean;
608 attributes: (VAttribute | VDirective)[];
609 }
610 export interface VEndTag extends HasLocation, HasParent {
611 type: "VEndTag";
612 parent: VElement;
613 }
614 export interface HasConcreteInfo {
615 tokens: Token[];
616 comments: Token[];
617 errors: ParseError[];
618 }
619 export interface VElement extends HasLocation, HasParent {
620 type: "VElement";
621 parent: VDocumentFragment | VElement;
622 namespace: Namespace;
623 name: string;
624 rawName: string;
625 startTag: VStartTag;
626 children: (VElement | VText | VExpressionContainer)[];
627 endTag: VEndTag | null;
628 variables: Variable[];
629 }
630 export interface VDocumentFragment extends HasLocation, HasParent, HasConcreteInfo {
631 type: "VDocumentFragment";
632 parent: null;
633 children: (VElement | VText | VExpressionContainer | VStyleElement)[];
634 }
635 export interface VStyleElement extends VElement {
636 type: "VElement";
637 name: "style";
638 style: true;
639 children: (VText | VExpressionContainer)[];
640 }
641 export {};
642}
643
644declare module 'vue-eslint-parser/ast/tokens' {
645 import type { HasLocation } from "vue-eslint-parser/ast/locations";
646 export interface Token extends HasLocation {
647 type: string;
648 value: string;
649 }
650}
651
652declare module 'vue-eslint-parser/ast/traverse' {
653 import type { VisitorKeys } from "eslint-visitor-keys";
654 import type { Node } from "vue-eslint-parser/ast/nodes";
655 export const KEYS: Readonly<{
656 [type: string]: readonly string[] | undefined;
657 }>;
658 function getFallbackKeys(node: Node): string[];
659 export interface Visitor {
660 visitorKeys?: VisitorKeys;
661 enterNode(node: Node, parent: Node | null): void;
662 leaveNode(node: Node, parent: Node | null): void;
663 }
664 export function traverseNodes(node: Node, visitor: Visitor): void;
665 export { getFallbackKeys };
666}
667