how to export html data to pdf in angularjs and javascript
HTML : <button onclick="pdfdownload()" class="btn btn-success"><i class="fa fa-download" ></i> Download PDf</button> <div class="table-responsive" id="exportthis"> this is demo text </div> Javascript: <script src="https://cdnjs.cloudflare.com/ajax/libs/pdfmake/0.1.22/pdfmake.min.js"></script> <script src="https://cdnjs.cloudflare.com/ajax/libs/html2canvas/0.4.1/html2canvas.min.js"></script> <script type="text/javascript"> function pdfdownload () { html2canvas(document.getElementById('exportthis'), { onrendered: function (canvas) { var data = canvas.toDataURL(); var docDefinition = { content: [{ ...