Skip to content

use modules false to enable webpack tree shaking#617

Closed
pravdomil wants to merge 3 commits intobabel:masterfrom
pravdomil:patch-1
Closed

use modules false to enable webpack tree shaking#617
pravdomil wants to merge 3 commits intobabel:masterfrom
pravdomil:patch-1

Conversation

@pravdomil
Copy link
Copy Markdown

@pravdomil pravdomil commented May 3, 2018

by default all modules are transpiled to commonjs therefore they cannot be statically analysed and tree shaking will not work

see https://stackoverflow.com/questions/45384170/how-to-fix-modules-with-moduleconcatenation-bailout-module-is-not-an-ecmascrip

@xtuc
Copy link
Copy Markdown
Member

xtuc commented May 3, 2018

Could you please add a note in the README to clarify why we need it?

Also that won't work a certain version of Webpack.

@pravdomil
Copy link
Copy Markdown
Author

@xtuc can you take a look at it?

@xtuc
Copy link
Copy Markdown
Member

xtuc commented Jun 15, 2018

Yes that better, could you please indicate which version of Webpack is required for modules: false?

@pravdomil
Copy link
Copy Markdown
Author

I think that webpack supports es6 modules from the beginning?

@Qix-
Copy link
Copy Markdown

Qix- commented Jul 20, 2018

This doesn't fix anything. I'm still getting ModuleConcatenation bailout: Module is not an ECMAScript module using the exact same configuration in the modified readme.

@loganfsmyth
Copy link
Copy Markdown
Member

This should be all set with #660 now.

@loganfsmyth loganfsmyth closed this Sep 1, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants