High-fidelity HTML to PDF conversion using Chromium
npm install printwellHigh-fidelity HTML to PDF conversion using Chromium's rendering engine.
``bash`
npm install printwell
`typescript
import { Converter, htmlToPdf } from "printwell";
// Simple conversion
const result = await htmlToPdf("
// With options
const converter = new Converter();
const pdf = await converter.htmlToPdf(
html,
{},
{
pageSize: "A4",
printBackground: true,
}
);
``
- Rendering: Full HTML5/CSS3 support via Chromium's Blink engine
- Large Documents: Automatic chunking and parallel rendering for documents >50MB
- Watermarks: Text and image overlays with positioning and opacity control
- Bookmarks: Table of contents and navigation structure
- Annotations: Highlights, sticky notes, and geometric shapes
- Rust: printwell on crates.io
- Python: printwell on PyPI
- CLI: printwell-cli on crates.io
AGPL-3.0