[]previous and next page

Visit

A visitor function: called with the node and its parent (null for the node the walk started at).

A visitor function: called with the node and its parent (null for the node the walk started at). Returning false from an enter skips the children of the node.

Import#

ts
import type { Visit } from "@shadow-js/compiler";

Signature#

ts
type Visit<N> = (node: N, parent: PluginNode | null) => void | false