Streaming Markdown parser for incremental rendering of markdown as it's written, targeting AI chat-style outputs. Current version 0.2.15. Actively developed with experimental features. Ships TypeScript types. Key differentiator: optimistic parsing – immediately renders partial tokens (e.g., inline code, bold) without waiting for closing markers, supporting selectable text during streaming. The library exposes a custom Renderer interface for DOM control, with built-in default renderer and logger renderer. Minimal bundle size (~3 kB gzipped). Requires Node >=20 for server-side use.
npm install streaming-markdownNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Demonstrates creating a parser with default_renderer, writing markdown chunks, and ending the stream.
Check the GitHub README for supported features before relying on it in production.
Update custom renderers to use 'class' attribute for language.
Upgrade Node.js to version 20 or later.
Use import statements or switch to ESM in your project.
Use named imports: import { parser } from 'streaming-markdown'Install with npm install streaming-markdown and ensure Node >=20.
Verify the correct import: import { default_renderer } from 'streaming-markdown'No dependency data recorded yet.