frappe_pdf
is an application built on the Frappe framework, designed specifically for rendering PDF files from HTML utilizing Google Chrome's headless mode. It addresses limitations present in wkhtmltopdf, providing better support for modern CSS features and overcoming various rendering constraints.
Note: Specify page size and margins in html to get a expected format.
example:
page {
size: A4;
margin: 5mm;
}
Google Chrome's headless mode is preferred due to its robust support for modern web standards, allowing for more accurate and reliable rendering of HTML to PDF compared to wkhtmltopdf. This choice ensures compatibility with the latest CSS features and addresses limitations encountered with wkhtmltopdf.
Once site is created, get the frappe-pdf
app
bench get-app https://github.com/Ponnusamy1-V/frappe-pdf.git
frappe_pdf
app on the site
bench --site sitename install-app frappe_pdf
Generate PDF using Google Chrome
in Print Settings
.mit