chartist-js / chartist

Simple responsive charts
https://chartist.dev
MIT License
13.35k stars 2.53k forks source link

ECMA script module support #1274

Closed yesparthasarathy closed 2 years ago

yesparthasarathy commented 3 years ago

Hi,

We are using the Chartist library in our Angular 10 project. we are getting below error

WARNING in depends on 'chartist'. CommonJS or AMD dependencies can cause optimization bailouts. For more info see: https://angular.io/guide/build#configuring-commonjs-dependencies

Can you please make chartist as ECMA module ?

technbuzz commented 3 years ago

I thing this is expected in todays days and age. With the like of wepback, parcel and so on we can take the advantage of treeshaking to reduce the bundle.

How you solved your problem. I am just including it the old way by adding it to angular.json?

Arantiryo commented 2 years ago

Since version 1.0 Chartist supports ESM and is tree-shakable. : )