Skip to content
Myr

break: include "exports" map w/ "types" conditions (#57)

Before adoption: this commit came in with the history the project adopted, so no landing records it.

The non-standard `package.json` field `module` was used. This pointed to a faux ESM file (Uses ESM syntax, but has a `.js` file extension in a package which doesn’t specify `"type": "module"`. ESM support was fixed by using the `.mjs` file extension for the ESM export and defining a proper `exports` field in `package.json. The types reflected a package that has the `module.exports.default` field. This was incorrect. The CommonJS types have now been fixed to use `export =`, which is the correct way to type modules that use `module.exports` assignments. Additional types were added for ESM support.

authored by Remco Haszing · committed by GitHub · parent 4a4eadd · Browse files · 3 files+26 added−6 removed
This commit

State

Before adoption: this commit came in with the history the project adopted, so no landing records it.

Diff stats

3 files+26 added−6 removed

  • other:+26 added−6 removed

3 files+26 added−6 removed

added:clsx.d.mts+6 added
modified:clsx.d.ts+9 added-5 removed
modified:package.json+11 added-1 removed