Files
fil/docs/snippets/rust/config/html_output.md
Henrik Jess Nielsen b4c07d3693
All checks were successful
Deploy fil (kreuzberg) / deploy (push) Successful in 49s
Nomad changes
2026-06-01 23:40:55 +02:00

15 lines
464 B
Markdown

```rust title="Rust"
use kreuzberg::{extract_file_sync, ExtractionConfig, HtmlOutputConfig, HtmlTheme, OutputFormat};
let config = ExtractionConfig {
output_format: OutputFormat::Html,
html_output: Some(HtmlOutputConfig {
theme: HtmlTheme::GitHub,
..Default::default()
}),
..Default::default()
};
let result = extract_file_sync("document.pdf", None, &config).unwrap();
println!("{}", result.content); // HTML with kb-* classes
```