Expand description
Who colors a fenced block.
markdown names no highlighter. The one this crate would otherwise reach
for is tree-sitter, whose C cannot be built for wasm32-unknown-unknown —
there is no libc to compile it against — so a web build would carry a
dependency it can never link. Installed once at boot like the theme
palette, and read at paint.
Functions§
- languages
- What the installed highlighter can color — the list a language picker offers, empty until someone installs one.
- set_
highlighter markdown::set_highlighter(cx, my_highlighter, my_languages)— call once at boot. Without it every fenced block paints in one plain run, which is what a document looks like before anyone has an opinion about its code.
Type Aliases§
- Highlighter
- Spans over
code, in bytes.Nonefor a language the caller cannot color.