jamsinclair / jSquash

Browser & Web Worker focussed image codec wasm bundles derived from the Squoosh App.
Apache License 2.0
241 stars 16 forks source link

Support cjs and umd in packages #6

Closed jamsinclair closed 1 year ago

jamsinclair commented 2 years ago

Currently the published NPM modules only expose esm modules. To increase compatibility with other developer environments we could also build valid cjs and umd bundles.

Should we? 🤔

jamsinclair commented 1 year ago

Should we? 🤔

It's now 2023, many popular packages now only offer ESM modules. The reason for this is ESM now has wide adoption and by providing other module fallbacks we're providing an unnecessary crutch on older ways.

We will take an opinionated stance of only offering ESM modules. Consumers can always transpile themselves as necessary.