1 unstable release
0.1.0 | Jan 26, 2024 |
---|
#51 in #preview
2KB
to-pdf
About
Installation
Add the following to Cargo.toml:
[dependencies]
to-pdf = { git = "https://github.com/bob22z/to-pdf" }
Usage
use to_pdf::ToPdf;
// Initialize with custom fonts
let to_pdf = ToPdf::new(FONT_PATH)?;
// Export to Pdf with typst text
let pdf_content = to_pdf.to_pdf(TYPST_TEXT)?;
// Preview as Svg with typst text
let svg_content_list = to_pdf.to_svg(TYPST_TEXT)?;
License
MIT