Adding third party libraries - Ionic 2

I’m trying to import a third party library following this guide but I can’t understand where I have to put the “import” statement.

I used Ionic Creator to have the “basic” app, I don’t have any “.ts” file

Could you please help me?

Without “.ts” file u cannot use third party libraries. Create one “.ts” file and bind the html template in .ts file using following syntax.

//Here comes the import statements
templateUrl: 'template path'
export class ClassName {

Hope this helps.

1 Like