I am trying to build a PDF viewing component for an Ionic 2 app. I have lots of experience of Angular 2, but not of Ionic.
The component will be built using pdf.js and have created the pdf.js asset to be included in my project as described on the github page. However, trying to
require is not defined
js folder (or something like this) in the
www folder; include the files needed and reference them from there. This folder is not emptied on build.
The root of the
www folder does not change and you can reference it as someting like ...
There should have some references in your
index.html file to the
build folder and maybe the
assets folder (icon); this concept of using a
js folder works the same. Only
assets will change.