kendo-angular icon indicating copy to clipboard operation
kendo-angular copied to clipboard

Commonjs warning with @progress/kendo-angular-intl/locales

Open destus90 opened this issue 5 years ago • 2 comments

After upgrading to Angular 10, the following warning is displayed after ng serve command:

WARNING in angular-v10\src\app\app.module.ts depends on  @progress/kendo-angular-intl/locales/fr/all. CommonJS or AMD dependencies can cause optimization bailouts.
For more info see: https://angular.io/guide/build#configuring-commonjs-dependencies

Repro: https://github.com/destus90/angular-v10-issues Clone it and run ng serve -c=fr. The similar issue with @angular/common/locales is here https://github.com/angular/angular/issues/37728

destus90 avatar Jun 25 '20 09:06 destus90

The warning can be ignored in the case of locales and timezones, as they do not export anything. They are not subject to tree-shaking and are marked with sideEffects: true.

That said, we'll consider switching to ESM. This was the case in old versions, but IIRC it caused issues with server-side rendering. There NodeJS expects CommonJS modules 🔀

tsvetomir avatar Jun 25 '20 10:06 tsvetomir

Just wondering if there is any update on moving this to ESM?

saerx avatar Nov 08 '22 17:11 saerx