Skip to main content

Module block

Module block 

Source
Expand description

Who paints a fenced block.

A consumer that needs a block of its own — a chart, a diagram, an embed — reaches for this rather than for a new crate::BlockKind. The vocabulary stays closed because markdown is the wire form and a new kind would have to own a syntax; a fence already has one. It round trips byte for byte, holds a caret in crate::Part::Code, and on a build that installs nothing it paints the source it always did.

Installed once at boot like the highlighter, and read at paint.

Functions§

set_block_renderer
markdown::set_block_renderer(cx, my_blocks) — call once at boot.

Type Aliases§

BlockRenderer
Paints the block a fence’s info string names, or None to leave it to the ordinary code block.