sayanee / angularjs-pdf

:page_facing_up: An AngularJS directive <ng-pdf> to display PDF files with PDFJS
http://sayan.ee/angularjs-pdf/
MIT License
494 stars 248 forks source link

Isolated scope #209

Open endorama opened 7 years ago

endorama commented 7 years ago

Hello @dennybiasiolli @NicoBurno, sorry for the long delay!

As I've seen no progression on this ( no pun intended! ), and I had a Torino OpenSource Saturday to spend on this, here is my implementation for the isolated scope.

This is a full refactor of the previous implementation :) All features are preserved ( apart custom http headers ).

The refactor is based on a factory object, which creates an object that can be used to manipulate the viewer status.

Please have a look and ask questions!

The NgPdfFactory should be more appropriately named NgPdfViewer.

Thanks!

endorama commented 7 years ago

@dennybiasiolli as this is a complete new version, may I propose to remove phantomjs and instead use the new chrome headless?

dennybiasiolli commented 7 years ago

@endorama yes, it's a good idea