Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

package.json module and main properties and unexpected behaviour with webpack 4 #6

Open
DmitryFillo opened this issue Dec 24, 2018 · 0 comments
Labels

Comments

@DmitryFillo
Copy link
Owner

"module" property points to es6 version of sources, but "main" for minified and browser-ready.
https://webpack.js.org/configuration/resolve/#resolve-mainfields - by default webpack uses browser -> module -> main, so it will find es6 sources and in common case babel transpiling of node_modules is disabled, so it will result in es6 code in the result build. Should be fixed, I suggest to add "browser" prop that should point to the minified version of this pkg

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant