1 | import type { PrecompileOptions, PrecompileOptionsWithLexicalScope } from '../parser/tokenizer-event-handlers';
|
2 | import type { SourceLocation } from '../source/location';
|
3 | import type { Source } from '../source/source';
|
4 | import type { SourceSpan } from '../source/span';
|
5 | import type { BlockSymbolTable } from '../symbol-table';
|
6 | import type * as ASTv1 from '../v1/api';
|
7 | import type { Resolution } from './loose-resolution';
|
8 | import { SymbolTable } from '../symbol-table';
|
9 | import * as ASTv2 from './api';
|
10 | import { Builder } from './builders';
|
11 | export declare function normalize(source: Source, options?: PrecompileOptionsWithLexicalScope): [ast: ASTv2.Template, locals: string[]];
|
12 |
|
13 |
|
14 |
|
15 |
|
16 |
|
17 |
|
18 |
|
19 |
|
20 |
|
21 |
|
22 |
|
23 | export declare class BlockContext<Table extends SymbolTable = SymbolTable> {
|
24 | readonly source: Source;
|
25 | private readonly options;
|
26 | readonly table: Table;
|
27 | readonly builder: Builder;
|
28 | constructor(source: Source, options: PrecompileOptions, table: Table);
|
29 | get strict(): boolean;
|
30 | loc(loc: SourceLocation): SourceSpan;
|
31 | resolutionFor<N extends ASTv1.CallNode | ASTv1.PathExpression>(node: N, resolution: Resolution<N>): {
|
32 | result: ASTv2.FreeVarResolution;
|
33 | } | {
|
34 | result: 'error';
|
35 | path: string;
|
36 | head: string;
|
37 | };
|
38 | isLexicalVar(variable: string): boolean;
|
39 | isKeyword(name: string): boolean;
|
40 | private isFreeVar;
|
41 | hasBinding(name: string): boolean;
|
42 | child(blockParams: string[]): BlockContext<BlockSymbolTable>;
|
43 | customizeComponentName(input: string): string;
|
44 | }
|