Tiptapex.Renderer.Node behaviour (Tiptapex v0.1.2)

Copy Markdown View Source

Behaviour for custom node (or mark) renderers passed to Tiptapex.Renderer.to_html/2 via the :nodes / :marks options.

children is the already-rendered, already-escaped iodata of the node's content. Return iodata; use Tiptapex.Renderer.HTML to build tags so attribute values stay escaped.

Summary

Callbacks

render(node, children, opts)

@callback render(node :: map(), children :: iodata(), opts :: map()) :: iodata()