Closed ryan-williams closed 2 months ago
In the meantime, I'm using a spacer element like:
<div style="height: 10em"></div>
While debugging, a border is helpful:
<div style="height: 10em; border: 1px solid black"></div>
You can do page breaks using this
<div style="page-break-before:always;"></div>
I've referenced back to @nuckle's answer a few times in the last 6mos, it seems to work in general (not just with mdpdf
) when saving web pages to PDF. Ty!
It would be neat if some markdown, HTML, or CSS sentinel value could be interpreted by
mdpdf
as a "page break."I love this tool, but often spend a lot of time futzing with CSS, or tweaking copy, to e.g. get a heading to flow to the next page (rather than dangling at the end of a page, with its content starting on the next page).
A couple options, off-hand:
--hr-page-breaks
: interpret Markdown---
(normally an HTML<hr/>
tag) as a page break<div class="page-break"></div>
or similar