Hi there! Are you looking for the official Deno documentation? Try docs.deno.com for all your Deno learning needs.

ASTVisitFn

A visitor is comprised of visit functions, which are called on each node during the visitor's traversal.

type ASTVisitFn<TVisitedNode extends ASTNode> = (
node: TVisitedNode,
key: string | number | undefined,
parent: ASTNode | ReadonlyArray<ASTNode> | undefined,
path: ReadonlyArray<string | number>,
ancestors: ReadonlyArray<ASTNode | ReadonlyArray<ASTNode>>,
) => any
;

§Type Parameters

§
TVisitedNode extends ASTNode
[src]

§Type

§
(node: TVisitedNode, key: string | number | undefined, parent: ASTNode | ReadonlyArray<ASTNode> | undefined, path: ReadonlyArray<string | number>, ancestors: ReadonlyArray<ASTNode | ReadonlyArray<ASTNode>>) => any
[src]