Interface Transformer

A transform is some algorithm that takes a AST subtree and makes any number of modifications to the given subtree. They cannot see or modify anything outside the given subtree. Transformers are assumed to behave like a set of pure functions.

Transformers are always applied bottom-up.

The most simple transformer is an empty object ({}). This is equivalent to a no-op transformer that does not change the given AST.

Hierarchy

  • Transformer

Implemented by

Properties

name?: string

An optional name useful for diagnostics.

Methods