Library Export Default Webpack Plugin: Rewrite as CommonJS#15710
Library Export Default Webpack Plugin: Rewrite as CommonJS#15710
Conversation
|
Do we have a rule for dropping the |
| @@ -0,0 +1,5 @@ | |||
| ## Unreleased | |||
There was a problem hiding this comment.
Is it master or unreleased?
There was a problem hiding this comment.
Master - we should update our docs
There was a problem hiding this comment.
Master - we should update our docs
See: #15740
The gutenberg/test/unit/jest.config.js Lines 6 to 8 in d08dcd8 These could be updated to avoid making assumptions, I think. In the meantime, however, it seems safer to keep them out of that directory. There are some some benefits to this as well:
|
|
Makes sense. Thanks 👍 |
|
See: https://medium.com/@nodejs/announcing-a-new-experimental-modules-1be8d2d6c2ff
There is also commonjs value proposed. We should add this new field to all packages and start using it with the script which picks which packages should be transpiled. This is going to solve the issue with special handling for src folder. |
gziolo
left a comment
There was a problem hiding this comment.
I now see that here the lock file needs to get regenerated as well. Our script on Travis seems to not work properly anymore.
In another pull request (I can't specifically recall), we tracked it back to an issue where |
368a8a1 to
3108745
Compare
|
Resolved |
Extracted from: #15226
This pull request seeks to expose the source of
LibraryExportDefaultWebpackPlugindirectly as its source, omitting it from the Babel transpilation build step. The proposed benefit is to reduce overhead by limiting the number of Babel-transpiled packages, to accurately reflect the current source as being CommonJS and, depending on the outcome of #15226, avoid dependencies on a built package from the project's own build tooling (Webpack). The main downside is fragmentation on which packages are and aren't transpiled by Babel.Testing instructions:
Verify build succeeds: