Open johnshields opened 3 years ago
Hello, I am currently getting this Error when using html2pdf with Angular and Ionic.
DOMException: Failed to set the 'adoptedStyleSheets' property on 'ShadowRoot': Sharing constructed stylesheets in multiple documents is not allowed
onExportPDF() { const options = { filename: 'job_report.pdf', image: {type: 'jpeg', quality: 0.98}, html2canvas: {scale: 2, logging: true, dpi: 192, letterRendering: true}, jsPDF: {unit: 'mm', format: 'a4', orientation: 'portrait'} }; const content: Element = document.getElementById('job-report'); html2pdf() .from(content) .set(options) .save(); }
Anyone have a know the issue to stop the DOMException? It works fine. The PDF comes out nice, but it's a nasty error to have in the console, and it makes my hamburger button for my side menu disappear.
DOMException
Same problem here
Hello, I am currently getting this Error when using html2pdf with Angular and Ionic.
Anyone have a know the issue to stop the
DOMException
? It works fine. The PDF comes out nice, but it's a nasty error to have in the console, and it makes my hamburger button for my side menu disappear.