SAP / spartacus

Spartacus is a lean, Angular-based JavaScript storefront for SAP Commerce Cloud that communicates exclusively through the Commerce REST API.
Apache License 2.0
741 stars 388 forks source link

Update dependencies to avoid unnecessary warnings #3601

Closed tobi-or-not-tobi closed 5 years ago

tobi-or-not-tobi commented 5 years ago

We currently get a number of warnings when a new application is installed:

warning ” > @spartacus/storefront@1.0.0" has incorrect peer dependency “@angular/animations@~8.0.0".
warning ” > @spartacus/storefront@1.0.0" has incorrect peer dependency “@angular/common@~8.0.0".
warning ” > @spartacus/storefront@1.0.0" has incorrect peer dependency “@angular/compiler@~8.0.0".
warning ” > @spartacus/storefront@1.0.0" has incorrect peer dependency “@angular/core@~8.0.0".
warning ” > @spartacus/storefront@1.0.0" has incorrect peer dependency “@angular/forms@~8.0.0".
warning ” > @spartacus/storefront@1.0.0" has incorrect peer dependency “@angular/platform-browser@~8.0.0".
warning ” > @spartacus/storefront@1.0.0" has incorrect peer dependency “@angular/platform-browser-dynamic@~8.0.0".
warning ” > @spartacus/storefront@1.0.0" has unmet peer dependency “@angular/pwa@^0.800.2".
warning ” > @spartacus/storefront@1.0.0" has incorrect peer dependency “@angular/router@~8.0.0".
warning ” > @spartacus/storefront@1.0.0" has unmet peer dependency “@angular/service-worker@~8.0.0".
warning ” > @spartacus/storefront@1.0.0" has unmet peer dependency “@ng-bootstrap/ng-bootstrap@4.1.0".
warning ” > @spartacus/storefront@1.0.0" has unmet peer dependency “@ng-select/ng-select@^2.13.2".
warning ” > @spartacus/storefront@1.0.0" has unmet peer dependency “@ngrx/effects@~8.0.1".
warning ” > @spartacus/storefront@1.0.0" has unmet peer dependency “@ngrx/router-store@~8.0.1".
warning ” > @spartacus/storefront@1.0.0" has unmet peer dependency “@ngrx/store@~8.0.1".
warning ” > @spartacus/storefront@1.0.0" has unmet peer dependency “@spartacus/core@latest”.
warning ” > @spartacus/storefront@1.0.0" has unmet peer dependency “@spartacus/styles@latest”.
warning ” > @spartacus/storefront@1.0.0" has unmet peer dependency “bootstrap@^4.2.1".
warning ” > @spartacus/storefront@1.0.0" has unmet peer dependency “core-js@^2.5.7”.

Having those warning indicates that we are providing too strict dependencies for no good reason. It would mean whenever a new dependency becomes available (and used when generating a new app using a later version angular-cli), new warnings will popup. We should improve the dependencies so that the these warnings will not show up. The key thing to do here is to add the major version with a caret (^), so that the latest minor and patch release will be used. On top of that, we should depend on the latest minor we like to use.

Task: Change spartacus dependencies:

The questionmarks indicate that i'm not sure how we fix those, please investigate.

giancorderoortiz commented 5 years ago

The warnings mentioned here are gone when installing release/1.0.1