package pipeline

Import Path
	github.com/d2lang/mathjax-go/internal/pipeline (on go.dev)

Dependency Relation
	imports 3 packages, and imported by 3 packages

Involved Source Files Package pipeline defines the narrow contracts between the TeX parser, MathML tree, and SVG output stages.
Package-Level Type Names (total 5)
/* sort by: | */
Compiler parses TeX into MathJax's internal MathML tree. Implementations must start each call with fresh macro, tag, and parser state. ( Compiler) Compile(tex string, display bool) (*mml.Node, error) *github.com/d2lang/mathjax-go/internal/tex.Compiler
FontCacheMode controls SVG glyph path caching. const FontCacheNone
Options controls a single conversion. Display bool Em float64 Ex float64 FontCache FontCacheMode Validate rejects values for which the MathJax 3.2.2 compatibility contract is undefined. func DefaultOptions() Options func Pipeline.Render(tex string, options Options) (string, error) func Typesetter.Typeset(root *mml.Node, options Options) (string, error) func github.com/d2lang/mathjax-go/internal/svg.(*Typesetter).Typeset(root *mml.Node, options Options) (string, error)
Pipeline joins independently implemented compiler and typesetter stages. Implementations should be immutable or allocate per-call state so Pipeline is safe for concurrent use. Compiler Compiler Typesetter Typesetter Available reports whether both stages are connected. Render runs a single stateless conversion.
Typesetter lays out an inherited-attribute-complete MathML tree and emits the bare SVG element used by D2. ( Typesetter) Typeset(root *mml.Node, options Options) (string, error) *github.com/d2lang/mathjax-go/internal/svg.Typesetter
Package-Level Functions (only one)
DefaultOptions reproduces html.convert(tex, {em: 16, ex: 8}) with the SVG output jax configured as {fontCache: "none"}.
Package-Level Constants (only one)
FontCacheNone emits a path for every glyph occurrence. This is the only mode in D2's frozen MathJax component and is currently the only supported mathjax-go mode.