hearsid / ng-html-to-pdf-save

Save HTML as pdf file on the browser with angularjs .
28 stars 35 forks source link

Cannot save PDF files #1

Closed mattwoPhre closed 7 years ago

mattwoPhre commented 8 years ago

HI devs!!! :) i would like to ask you one thing: i cannot save my html in a pdf with this library. I think that there's a problem in createPDF() function, because after that getCanvas() function is done, the promise in then is broken because it doesn't create pdf or execute the function inside .then either.

UPDATE: i've modified a little bit the library and put error condition in resolve, so it logs me "CanvasRenderer is not defined". I googled a bit and i've found that maybe it's a jspdf version problem.

UPDATE 2: i have to put jspdf.debug.js and all works! but there's problem with pdfs with more than one page and quality. If you don't mind, can i make pull request? :)

hearsid commented 8 years ago

@mattwoPhre Sorry for the late reply. Yes, please make the pull request 👍

hearsid commented 7 years ago

Have fixed the same in PR https://github.com/hearsid/ng-html-to-pdf-save/pull/2