1 | import type { ScopeManager } from '@typescript-eslint/scope-manager';
|
2 | import type { ParserOptions, TSESTree } from '@typescript-eslint/types';
|
3 | import type { AST, ParserServices } from '@typescript-eslint/typescript-estree';
|
4 | import type { VisitorKeys } from '@typescript-eslint/visitor-keys';
|
5 | import type * as ts from 'typescript';
|
6 | interface ESLintProgram extends AST<{
|
7 | comment: true;
|
8 | tokens: true;
|
9 | }> {
|
10 | comments: TSESTree.Comment[];
|
11 | range: [number, number];
|
12 | tokens: TSESTree.Token[];
|
13 | }
|
14 | interface ParseForESLintResult {
|
15 | ast: ESLintProgram;
|
16 | scopeManager: ScopeManager;
|
17 | services: ParserServices;
|
18 | visitorKeys: VisitorKeys;
|
19 | }
|
20 | declare function parse(code: ts.SourceFile | string, options?: ParserOptions): ParseForESLintResult['ast'];
|
21 | declare function parseForESLint(code: ts.SourceFile | string, parserOptions?: ParserOptions | null): ParseForESLintResult;
|
22 | export { parse, parseForESLint };
|
23 | export type { ParserOptions } from '@typescript-eslint/types';
|
24 |
|
\ | No newline at end of file |