Printing html to pdf:
.keep-together {
page-break-inside: avoid;
}
.break-before {
page-break-before: always;
}
.break-after {
page-break-after: always;
}
How to insert a page break in HTML so wkhtmltopdf parses it?
Welllllll. yes and no.
It depends on the page. Look at any book, what do you see? Lots of words and a couple of pictures. Gutenberg would recognize this.
In fact ALL our text processing tools are for pages Gutenberg would have no problem with.
What this code does is break only in the middle of text. Therefore it assumed any DIV or TABLE will never be larger than one printed page.
Modern websites may not obey this Gutenberg era rule. You and I both have websites this can not work on.
I'll be interested to see what it does with these. Worst case: blank pages.