penumbra-zone / web

Apache License 2.0
12 stars 15 forks source link

Convert from CJS to ESM #749

Closed grod220 closed 2 months ago

grod220 commented 6 months ago

We should move all CommonJS (CJS) usages to ECMAScript Modules (ESM). Should allow us to better take advantage of tree shaking 🌳 given ESM is more statically analyzable compared to CJS. This means potentially smaller bundles. Also, CJS is slowly phasing out in the javascript ecosystem.

Todo:

turbocrime commented 5 months ago

i think our only cjs modules are actually eslint and tailwind

turbocrime commented 5 months ago

is this still relevant if we are publishing ts packages

turbocrime commented 2 months ago

completed by https://github.com/penumbra-zone/web/pull/1460