Expand description
A library for rendering Markdown documents with syntax highlighting.
This crate provides functionality to render Markdown content with rich text formatting and syntax highlighting for code blocks using tree-sitter.
§Examples
use mq_view::render_markdown_to_string;
use mq_markdown::Markdown;
let markdown: Markdown = "# Hello\n\n```rust\nfn main() {}\n```".parse().unwrap();
let rendered = render_markdown_to_string(&markdown).unwrap();
println!("{}", rendered);Structs§
- Render
Config - Configuration for rendering markdown
- Syntax
Highlighter - Syntax highlighter supporting various programming languages and HTML.
Functions§
- render_
markdown - Render a Markdown document to a writer with syntax highlighting and rich text formatting.
- render_
markdown_ to_ string - Render a Markdown document to a String with syntax highlighting and rich text formatting.
- render_
markdown_ with_ config - Render a Markdown document to a writer with custom configuration.