Skip to content

Conversation

@haydenbleasel
Copy link

Howdy!

This PR migrates example apps from react-markdown (plus plugins) to Streamdown, a modern markdown renderer purpose-built for AI streaming applications we're building at Vercel. We're using it on a few projects like ChatSDK and thought you might enjoy it too.

Benefits

  • Built for AI streaming - Handles incomplete markdown gracefully during real-time content generation
  • Fewer dependencies - Replaces 5 packages (react-markdown, rehype-highlight, rehype-raw, rehype-sanitize, remark-gfm) with 1
  • Better out-of-box experience - Built-in Tailwind typography, syntax highlighting, and GFM support
  • Enhanced security - Native protection against malicious markdown and prompt injection
  • CJK language support - Proper emphasis rendering for Chinese, Japanese, and Korean
  • Performance optimized - Lots of effort gone in to memoization, LRU caches, etc. to make the fastest and most performant markdown streaming experience.
  • Interactive code blocks and tables - Users can download and copy tables / code block data
  • Mermaid support - built in support for Mermaid diagrams

Also, while I was here I fixed a handful of dependency issues (many unused, one missing).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant