-1

Anyone knows a proper way to print a PDF document based on data i am getting from a backend provider?

I have tried using this solution Print Html template in Angular 2 (ng-print in Angular 2) , but it's not always convinient, mainly because am manipulating large data with various directives (such as *ngFor) that cannot be used some aspects of that solution.

Muhammad Usman
  • 1,220
  • 13
  • 22

1 Answers1

0

This is probably best done on the server side. I would create a webservice that generates a PDF then call it from the angular app. There are a ton of frameworks to generate PDFs on server side tech. Itext itesxtsharp etc.

cobolstinks
  • 6,801
  • 16
  • 68
  • 97