-
-
Notifications
You must be signed in to change notification settings - Fork 902
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: provide browser versions independent from module system
Probably will fix #378 Currently main field is used for node and module for browser build. This is not entierly correct. Webpack can be used to build node apps. Though module is always preferred over main. For browser versions there is a special field. In this diff I added esm support for both node and browser. rollup-plugin-node-resolve look at browser field as well and prefer it to bundle umd. https://webpack.js.org/configuration/resolve/#resolvemainfields https://github.com/rollup/plugins/tree/master/packages/node-resolve#browser https://github.com/defunctzombie/package-browser-field-spec
- Loading branch information
Showing
5 changed files
with
80 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters