Open userquin opened 7 months ago
@userquin We provide ES6 and commonjs in the package. If you're having issues with a specific framework/build toolchain let us know.
Checking types here https://arethetypeswrong.github.io/?p=%40mdi%2Fjs%407.3.67
Check also https://publint.dev/@mdi/js@7.3.67
You should add package exports.
@userquin Good call we'll add "exports"
in the next release. Updated the title of the bug to reflect this.
Just build the package, generate the tgz and upload it to first url, should be ESM in node 16 ESM.
Thay's why I create mdi-js-es package https://github.com/unplugin/unplugin-auto-import/pull/451
This is really needed, currently if we bundle using webpack all icons are included meaning if you just use 2 icon you still get a 3MB sized bundle of icons.
@userquin Good call we'll add
"exports"
in the next release. Updated the title of the bug to reflect this.
Any idea of when the new version will be released?
Right now we're thinking of adding...
{
".": "./mdi.js",
"./*": "./glyph/*/*.js",
}
This would allow '@mdi/js/account'
-> glphy/account/account.js
.
See the PR I created, you also need to export the Typescript interface or it could not be used with moduleresolution node16 or later
Any updates on when this will be merged in? Looking to use this and move away from MUI framework but holding us back cause of ESM support.
Feel free to use https://github.com/userquin/mdi-js-es here, if so, I'll deprecate my package/repo.