PureGoPDF
An HTML-to-PDF converter written from scratch in pure Go and being open sourced. It implements its own layout engine with support for block context, flexbox layout, CSS variables, tables, and math functions like calc(), min(), and max(). It supports @page rules, optional in-HTML section-based headers/footers with full CSS, 100%-height page matching, forced page breaks inside flexbox containers, and correct page-break: avoid behavior. The author reports it is 10x-15x faster than wkhtmltopdf, 80x-100x faster than pagedjs, 2x faster than PrinceXML, and produces the smallest PDF file sizes. String-set, string, counter, and target-counter paged-media features are on the roadmap.
What it addresses
The author got tired of using headless browsers for HTML-to-PDF conversion for various reasons and wanted a fast, reliable pure-Go alternative.
Shared over time
Each entry reflects what was shared on that date. Details may have changed since then.
PureGoPDF
An HTML-to-PDF converter written from scratch in pure Go and being open sourced. It implements its own layout engine with support for block context, flexbox layout, CSS variables, tables, and math functions like calc(), min(), and max(). It supports @page rules, optional in-HTML section-based headers/footers with full CSS, 100%-height page matching, forced page breaks inside flexbox containers, and correct page-break: avoid behavior. The author reports it is 10x-15x faster than wkhtmltopdf, 80x-100x faster than pagedjs, 2x faster than PrinceXML, and produces the smallest PDF file sizes. String-set, string, counter, and target-counter paged-media features are on the roadmap.
Problem: The author got tired of using headless browsers for HTML-to-PDF conversion for various reasons and wanted a fast, reliable pure-Go alternative.
Audience: Initially for the author's internal use, now being open sourced
Posted by @radva42 · Original source ↗
Source text · @radva42 · · Source ↗
I am working on a HTML-to-PDF converter written from scratch in pure Go. I got tired of using headless browsers for various reasons and decided to give it a try and implement something that I can use internally.