Closed NoroleakIng closed 1 year ago
Found the solution by using windowHeight.
html2pdf(document.getElementById('export-to-pdf'), { filename: 'download.pdf', margin: 5, html2canvas: { scale: 5, imageTimeout: 15000, logging: true, useCORS: true, allowTaint: true, letterRendering: true, height: window.outerHeight + remainingHeight, windowHeight: window.outerHeight + remainingHeight, }, pageBreak: { mode: ['avoid-all', 'css'] }, })
When I download to pdf, it's able to get or render what shows on the screen but not all, and everything else after that is blank. Is there any solution to this?
html2pdf(document.getElementById('export-to-pdf'), { filename: 'download.pdf', margin: 5, })