Creating PDFs in Quasar / Electron project #12964
Replies: 6 comments 9 replies
-
|
Just some notes. Looking into PDFTron, but it seems to be a paid item. My user base is TINY. LIke really I will sell probably 150 copies of my software, so I really need a solution that's free. Looking at: https://github.com/praharshjain/Electron-PDF-Viewer |
Beta Was this translation helpful? Give feedback.
-
|
Looking at PDFjs-dist, but it looks like that is HTML5, and needing to use it as electron on a desktop application, I think I can't use HTML5, I have to use pdfjs... hm okay not sure about that. Can anyone clarify? |
Beta Was this translation helpful? Give feedback.
-
|
Gaaah this is killing me. Not being able to get PDFs to work in my project would be a show stopper. I'm getting the error (above) with vue-html2pdf, so my application is not recognizing it at all. Looking at https://github.com/eKoopmans/html2pdf.js but when I copy the code sandbox https://codesandbox.io/s/xlnzq7y28q?file=/App.vue:116-167 someone wrote, I get nothing. Back to google I guess. |
Beta Was this translation helpful? Give feedback.
-
|
My latest attempt is using jsPDF, and it may actually be working... I gotta play around with it for a while. |
Beta Was this translation helpful? Give feedback.
-
|
You might have solved it with external libs but given that you use electron and if you don't need some custom viewer just embed it with iframe. And for creating pdf use built in print to pdf win.webContents.printToPDF to which none other pdf lib can come close if you want to convert html to pdf. |
Beta Was this translation helpful? Give feedback.
-
|
Just here out of the blue... I've found this works great&installs easy as a pdf viewer: https://qpdfviewer.netlify.app/all-about-qpdfviewer/what-is-qpdfviewer Just one note; being a n00b I lost an abysmal amount of time on this: I am using pdfjs in my front end for pdf viewing, but also in my backend (nodejs + express + nodemon) for pdf processing. It took me a while to understand those two implementations are completely separate and backend one doesn't involve webkit. Just leaving this here. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
I've been spending a lot of time trying to find a PDF creator/viewer I can use with my Quasar/Electron project.
It looks like app-extension-qpdfviewer doesn't work with electron (waiting on a reply to make sure). quasarframework/app-extension-qpdfviewer#7
From what I understand, using electron, I need to use the pdf.js version, and not the html5 version (though I'm still trying to understand it all).
I've been trying to find some electron & pdf.js tutorials, but since I'm still really new to electron I am having difficulty implementing them into my quasar/electron app. Is pdf.js something I should be looking into using raw with my application?
This is one of the tutorials I find confusing: https://www.pdftron.com/blog/electron/how-to-build-an-electron-pdf-viewer/
Can anyone point me to a good tutorial, or give me information, on using creating PDFs with Quasar & Electron?
Thanks.
Beta Was this translation helpful? Give feedback.
All reactions