Use javascript plugin/widget and/or angular2 plugin

Hi,

I want to use a javascript widget, or a plugin.
For example, a slider:

In normal HTML/js I will include in my html this two lines (for example, a jquery slider):

How do I achieve this in ionic 2 / angular 2.

  1. In my case, I want to use datatables
    I found this
    https://www.npmjs.com/package/angular2-datatable

Is it possible, and how to do it, to use angular 2 plugins

There’s literally exact step by step instructions on how to install and use it in the link you posted…so…not really sure what you want from us…

About question one. I want to know how to use javascript libraries, as I explained.

And question two, the link explain it for angular. So simply would be as question one, but with angular instead of javascript.

My 2nd question could be rephrased as:
Is it the same to talk about about angular 2 and ionic 2?
If I follow steps in the link, nothing will fail in a ionic project?

Ah, okay, yes, rephrasing it helped. For the most part yes, you can talk about them as if they were the same. Ionic 2 uses Angular 2, and provides extra styles and components to make mobile app development easier.

There are some special cases where Ionic 2 differes, like it doesn’t user the Angular router, it uses it’s own Navigation Controller, but those details aside they are one in the same.

Ok, thanks!.

So question 1 is left =)

The term “widget” is so overloaded that it’s become pretty meaningless. Yes you can use JavaScript libraries in Ionic applications. Yes you can even use jQuery, although most every time I’ve seen somebody talking about wanting to use this or that jQuery thingy, an Angular alternative exists, and that should always be your preferred strategy. Read this.

Thank you @rapropos Useful link.

But… Do I have to choose a plugin/package that is available here, is that right?:
https://www.npmjs.com/search

I have realized that the following two lines in my first question did not show up

<script src="http://code.jquery.com/jquery-latest.min.js"></script>
<script src="jquery.slides.min.js"></script>

So for example, this one I have mentiones.
I have to look it up in npm, and if it’s not there, i can’t use it ?

If not, can someone make or put here a comprehensive tutorial?

I leave thi link also, for other readers:
https://x-team.com/blog/include-javascript-libraries-in-an-ionic-2-typescript-project/

Ionic has a Slides component.

Yes I know.

I put slider as an example. But what if I want another slider?

Or a component that is not present in ionic (I do not have an example right now)