Skip to main content

Module math

Module math 

Source
Expand description

Optional math rendering hooks.

Upstream Mermaid renders $$...$$ fragments via KaTeX and measures the resulting HTML in a browser DOM. Merman models math rendering as an operation-scoped backend. An operation without one rejects typed diagrams that contain delimited math instead of emitting the source as plain text. The math feature installs the pure-Rust RaTeX backend by default; hosts may still supply another implementation explicitly.

Structs§

NodeKatexMathRenderer
Optional KaTeX backend that shells out to a local Node.js toolchain.
NoopMathRenderer
Explicit no-op math renderer for hosts that want a backend which declines every label.

Traits§

MathRenderer
Optional math renderer used to transform label HTML and (optionally) provide measurements.