You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The generation example was improved, and now in the 2.2.0 version it is possible to install the fonts provided by pdfmake by default, making it easier to understand how to use it.
It will probably solve your problem:
<script setup>
import { usePDF } from'vue3-pdfmake';constpdfmake=usePDF({ autoInstallVFS:true})constonGenPDF= () => {pdfmake.createPdf({ content: ['Hello World From PDFMake!', ] }).download();}
</script>
<template>
<button@click="onGenPDF">Click here for download demo pdf</button>
</template>
I just tried this package and followed the README/demo, but getting blank page in the output.
I am not sure if I am supposed to pass any options inside pdf.createPdf() method.
Sharing the stackblitz link
https://stackblitz.com/edit/vitejs-vite-q2br2u
The text was updated successfully, but these errors were encountered: