uiuniversal / ngu-carousel

Angular Universal carousel
https://ngu-carousel.netlify.app
MIT License
332 stars 105 forks source link

Can't use this library with ng v12.0.2 #331

Closed Parsa-Sedigh closed 3 years ago

Parsa-Sedigh commented 3 years ago

When I run: ng update @angular/cli @angular/core , it gives me incompatible peer dependency error: Package "@ngu/carousel" has an incompatible peer dependency to "@angular/common" (requires "^10.0.4" (extended), would install "12.0.2"). Package "@ngu/carousel" has an incompatible peer dependency to "@angular/core" (requires "^10.0.4" (extended), would install "12.0.2"). × Migration failed: Incompatible peer dependencies found. Peer dependency warnings when installing dependencies means that those dependencies might not work correctly together. You can use the '--force' option to ignore incompatible peer dependencies and instead address these warnings later.

Crefelder commented 3 years ago

For me too - "ng update" was automatically removing my "hammerjs": "^2.0.8", package from package.json. Then i tried it with adding the {HammerModule} from '@angular/platform-browser'; in app.module.ts and also everywhere i used the @ngu/carousel module that is needing hammerjs. But always gaves me "The target entry-point "@ngu/carousel" has missing dependencies: - hammerjs"

After installing hammerjs again in package.json dependencies, it was working again. would also like to remove the hammerjs package and only use HammerModule. -> npm install hammerjs --save

Parsa-Sedigh commented 3 years ago

ng update" was automatically removing my "hammerjs": "^2.0.8", package from package.json.

Why it would do that? Did you open an issue on angular repo?

Crefelder commented 3 years ago

Not sure, could be because it should be replaced by HammerModule, now.

stones commented 3 years ago

HammerJS is CommonJS so it can't be tree shaken.

santoshyadavdev commented 3 years ago

Just release 4.0.0 please try and give feedback 😊