disable pdf library

This commit is contained in:
nurafrinaalimi16
2024-04-22 10:35:28 +08:00
parent 4c0415dcb2
commit 30e4738ca9
@@ -82,9 +82,6 @@
<script>
import html2canvas from 'html2canvas';
import jsPDF from 'jspdf';
export default {
data: function () {
return {
@@ -128,16 +125,16 @@ export default {
}
},
downloadPDF() {
const table = document.getElementById('voterTable');
// downloadPDF() {
// const table = document.getElementById('voterTable');
html2canvas(table).then(canvas => {
const imgData = canvas.toDataURL('image/png');
const pdf = new jsPDF();
pdf.addImage(imgData, 'PNG', 0, 0);
pdf.save('kehadiran-pengundi.pdf');
});
},
// html2canvas(table).then(canvas => {
// const imgData = canvas.toDataURL('image/png');
// const pdf = new jsPDF();
// pdf.addImage(imgData, 'PNG', 0, 0);
// pdf.save('kehadiran-pengundi.pdf');
// });
// },
},