Can someone suggest a reliable way to print the current doc page to a PDF file?
I’ve managed to get almost reliable rendering by using the html2pdf and a static/css/pdf.css file customized for my output.
The main problem is that the output in the PDF file is truncated at the bottom for many (but not all) pages, and the amount that’s missing seems to be random. I don’t have any other issues like bad rendering of objects (including images), “sticky” headers or footers, etc.
This hasn’t been discussed here for around two years. In that time, perhaps one of you has found a reliable solution? Thanks in advance.
I don’t see how that is related in any way to Hugo. Nevertheless: Printing a HTML document to PDF depends on the browser as well as the operating system. There probably is not a single solutiong working on all platforms and in all browsers. I suggest that you create a print CSS (@media print…
, details here) and print from Chrome. That has, AFAICT, the best support for print-specific rules.
In any case: Your chances to get help for this issue are a lot better in forums focusing on HTML and/or CSS. And you better provide a sample URL exhibiting the issue and information about your setup (OS, browser, etc). Otherwise, it’s impossible to reproduce what you’re seeing.
Thanks for the great ideas!