html2pdf.js
html2pdf.js copied to clipboard
Fix pagebreaks when explicit width set
Currently, setting an explicit width in the html2canvas options (e.g. html2canvas: { width: 1000 }) breaks the page height calculations in pagebreaks.js. This results in the overflow/gap calculation being wrong and an attempted pagebreak halfway through a page.
This short PR fixes the page height calculation.