Skip to content

Interface: AstBuilder<TNode> ​

Defined in: ast/ast-builder.ts:11

Fluent builder contract that compiles declarative configuration into a passive AST node.

Builders are copy-on-write immutable and remain separate from the passive AST records they emit via toAST().

Extended by ​

Type Parameters ​

Type ParameterDefault typeDescription
TNode extends ASTNodeASTNodePassive AST node type produced by this builder.

Methods ​

toAST() ​

ts
toAST(): TNode;

Defined in: ast/ast-builder.ts:20

Compiles the current builder configuration into a deeply frozen passive AST node.

Validates required builder invariants at compilation time and returns an immutable plain-object AST representation containing zero execution methods.

Returns ​

TNode

Deeply frozen passive AST node.

Released under the MIT License.