Angular-calendar: Angular version 10 - CommonJS import warnings

Created on 25 Jun 2020  路  8Comments  路  Source: mattlewis92/angular-calendar

Describe the bug

When building with the new angular version 10 angular-calendar triggers several warnings caused by using CommonJS dependencies instead of ecmascript module.

For example: .../app.module.ts depends on angular-calendar/date-adapters/date-fns. CommonJS or AMD dependencies can cause optimization bailouts.

You can read more about why this might be a problem at angular.io.
I was wondering wether this could be fixed as it may improve bundle sizes significantly when building.


Minimal reproduction of the problem with instructions

Update project to angular 10.0 and run ng build.

Screenshots

Versions

  • @angular/core: 10.0.0
  • angular-calendar: 0.28.16
  • Browser name and version: any

Most helpful comment

nice ! it works for me right now

All 8 comments

Thanks so much for opening an issue! If you'd like me to give priority to answering your issue or would just like to support this project, then please consider sponsoring me

Oh yeah that is not good at all, we should be shipping ESM to npm for the date adapters, thanks for bringing it to my attention! I will get this fixed in the next major version 馃槃

any update ?

I am seeing the same warnings. Request you to kindly update your package.

Hey folks, thanks for your patience on this, I've been a little bit busy the last few months but finally had the time this weekend to put out a fix. If you update to 0.28.17 then it should fix the warning message and your bundle sizes should be a little bit smaller as a result 馃槃

Thank you so much. The update did remove so many warnings. There is only one warning that's remaining though.

WARNING in frontend\node_modules\angular-draggable-droppable__ivy_ngcc__\fesm2015\angular-draggable-droppable.js depends on '@m
attlewis92/dom-autoscroller'. CommonJS or AMD dependencies can cause optimization bailouts.

Thank you so much. The update did remove so many warnings. There is only one warning that's remaining though.

WARNING in frontend\node_modules\angular-draggable-droppable__ivy_ngcc__\fesm2015\angular-draggable-droppable.js depends on '@m
attlewis92/dom-autoscroller'. CommonJS or AMD dependencies can cause optimization bailouts.

I've just noticed that as well when testing, please give 0.28.18 a go, it should get rid of it 馃槃

nice ! it works for me right now

Was this page helpful?
0 / 5 - 0 ratings

Related issues

AstRonin picture AstRonin  路  4Comments

vinay13 picture vinay13  路  3Comments

chaouiy picture chaouiy  路  3Comments

agilob picture agilob  路  3Comments

teodoramalec picture teodoramalec  路  4Comments