[core] Add `exports` to the package.json
See original GitHub issue- I have searched the issues of this repository and believe that this is not a duplicate.
Summary 💡
An exports property in the package.json of @material-ui/icons (and other packages), to aid discovery of the officially exported modules. To support CDNs such as https://jspm.org/
Examples 🌈
"exports": { "./*": "./*.js" }
Motivation 🔦
I want to consume material-ui via the JSPM CDN, but due to a lack of exports, it has to work out for itself what modules should be exported, and some icons are missing.
Issue Analytics
- State:
- Created 2 years ago
- Reactions:3
- Comments:6 (4 by maintainers)
Top Results From Across the Web
[core] Add `exports` to the package.json · Issue #26254 - GitHub
I want to consume material-ui via the JSPM CDN, but due to a lack of exports, it has to work out for itself...
Read more >Exports in package.json - DEV Community
I'm a front-end developer and ship my code via npm-packages. ... @some/vendors/index.ts export { createStore } from '@reatom/core'; ...
Read more >Modules: Packages | Node.js v19.3.0 Documentation
Existing packages introducing the "exports" field will prevent consumers of the package from using any entry points that are not defined, including the...
Read more >package.json - npm Docs
json are the name and version fields as they will be required. The name and version together form an identifier that is assumed...
Read more >Node: Exports field in package.json is not working
I couldn't get exports to work. This is how I worked around it. I had to change the build + publish only the...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Ok, finally got our app updated to MUI 5.0.0-beta.2 - would the core MUI team still be receptive to have
exports
added to the package.json files, so that the future CDN based systems (JSPM/Skypack etc) can make use of this to know what modules are officially exported from MUI packages?Nothing has changed about that. Be aware that a
"exports": { "./*": "./*.js" }
does not work for us: https://github.com/mui-org/material-ui/pull/26264#issuecomment-843095408