Repository navigation
Releases
Releases · ofershap/pagemill
v0.1.0
First public release of pagemill.
pagemill renders HTML to PDF or PNG from Go in one call: it downloads a pinned chrome-headless-shell build from the official Chrome for Testing endpoint once, caches it, and renders with real browser layout — flexbox, grid, web fonts, your CSS as-is. No service to run, no Node, no wkhtmltopdf.
Use:
go get github.com/ofershap/pagemill@v0.1.0
pdf, err := pagemill.HTML(invoiceHTML)
png, err := pagemill.PNG(invoiceHTML)
Honest costs (measured, in the README): 128MB one-time download, 277MB on disk, a full Chrome process per render, ~130-190ms per render with a cached browser. It removes the plumbing, not the browser. Container usage, BrowserPath for CI images, and version pinning are covered in the README.