Skip to main content

Module blocks

Module blocks 

Source
Expand description

Block segmentation, ported from markmend/core/src/preprocess/vendored/parse-blocks.ts (itself ported from vercel/streamdown). Splits markdown into stable blocks so only the trailing block needs re-parsing as content streams in.

Functionsยง

parse_markdown_into_blocks
Split markdown into logical blocks. Footnotes collapse the whole document into a single block; unclosed HTML tags and unclosed $$ math merge across blocks.