jspdf angular open pdf in iframe code example
Example: jspdf preview before download
<div id="example1"></div>
<script src="/js/pdfobject.min.js"></script>
<script src="/js/jspdf.min.js"></script>
<script>
PDFObject.embed(createPDF(), "#example1");
function createPDF() {
var doc = new jsPDF();
doc.setFont("helvetica");
doc.setFontStyle("bold");
doc.setFontSize(20);
doc.text('TEST PDF...', 105, 20, 'center');
return doc.output('datauristring');
}
</script>