Posted in Uncategorized

[Cordova] How to preview PDF file inside Cordova project

cordova_logo

Hi all, I faced this challenge for my tasks list. After searching a lot on Internet with various solutions:

  • Using InAppBrower: this plugin can open PDF for preview but it will open a certain PDF reader application on device not inside our Cordova project
  • PDFObject: hmmm, I tried use it but I faced compile error about import it into my project, I did not fix that issue because of time limitation.

Finally, I found the solution which solved my challenge 🙂 (it saved my life 🙂 ).

Below is result:

screenshot_2016-10-18-14-25-43

About the detail, please follow steps of the “example” at my github

I preferred that solution at sayanee’s github. Thank him very much 🙂

You also install that plugin by npm (Ref detail at here):

npm install angular-pdf

Hope it is helpful 🙂

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s