JQuery plugin does not work on my computer but on other

0

I have a project created with Angular + JHipster.

I needed to insert a slider called Owl Carousel, but it did not work. Suddenly, I realized that I was receiving the following error in the component.ts file of the module where I want to use it:

Property 'owlCarousel' does not exist on type 'JQuery<HTMLElement>'

I realized that the problem is in my computer, because the exact same project works on other computers, and the other GIT branches do not work on my computer.

All these problems appeared just after I tried to install JQuery from npm install jquery

Among the solutions I tried, was to add an interface to Jquery in the file typings.d.ts in the following way:

interface JQuery {
    owlCarousel(options?: any): any;
}

I'm using nvm 5.6.0, and I'm using node 8.11.2

    
asked by Gino 24.06.2018 в 09:40
source

0 answers