xaviergonz / js-angusj-clipper

Polygon and line clipping and offsetting library (Javascript) - a port of Angus Johnson's clipper

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Support ES Modules

AlexanderMelde opened this issue · comments

Hello Javier,
when importing your script into typescript Angular projects, the following warning appears:

Warning: [file] depends on 'js-angusj-clipper/web'. CommonJS or AMD dependencies can cause optimization bailouts.
For more info see: https://angular.io/guide/build#configuring-commonjs-dependencies

I have reviewed the source code here and it seems like this project is not yet a ES Module.
For any modern typescript project, it would be helpful if you could provide a ES6 Module.
You can read more about the benefits of ESM here and here.

Let me know if I can help during the implementation of this.

Best,
Alexander