Question

I am looking for a solution to generate pdf from (html + css + javascript) using AngularJs.

I tested two solutions:

  • jsPDF (it does not take the css)
  • Shrimp (based on Ruby)

which do not work for me.

How can I do it?

Was it helpful?

Solution

After all this, I discovered the excellent PhantomJS.

The binary was easily installed on the server with no additional dependencies required, and came with a great deal of example code, including a working ‘print to PDF’ function out-of-the-box. With some minor tweaks, we customized the script for our use case, and had a PDF copy of our webpages in minutes. PhantomJS has been around since 2011 and is used by a variety of open source products, listed on their websit

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top