Skip to main content

Crate ox_content_renderer

Crate ox_content_renderer 

Source
Expand description

Markdown renderer for Ox Content.

This crate provides a renderer that converts Markdown AST to HTML and other output formats.

§Example

use ox_content_allocator::Allocator;
use ox_content_parser::Parser;
use ox_content_renderer::HtmlRenderer;

let allocator = Allocator::new();
let source = "# Hello World\n\nThis is a paragraph.";
let parser = ox_content_parser::Parser::new(&allocator, source);
let document = parser.parse().unwrap();

let mut renderer = HtmlRenderer::new();
let html = renderer.render(&document);

Structs§

HtmlRenderer
HTML renderer.
HtmlRendererOptions
HTML renderer options.

Enums§

CodeAnnotationSyntax
RenderError
Render error.

Traits§

Renderer
Trait for rendering Markdown AST to various output formats.

Type Aliases§

RenderResult
Result type for rendering operations.