-
-
Notifications
You must be signed in to change notification settings - Fork 9k
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
Named chunks plugin #4553
Named chunks plugin #4553
Conversation
f27dfc2
to
50a7335
Compare
The most important CI builds succeeded. Great work so far. |
Thanks |
Hi @timse, Can I use your NamedChunksPlugin to output chunks with a static name ? I have this output webpack config that generate chunks filename containing chunkhash:
That generate the chunk with good filename static-named-chunk.js. Thanks for your help |
@lucaperret see here: https://github.com/webpack/webpack/pull/4553/files#diff-fdd2eb1e89fc79f2b86af37851152b92 not sure what exactly you look after, but u need to use this plugin to specify a name if you want a name. |
@timse I use |
I doubt that, thats also not the purpose of this plugin. |
Nice Work, That is exactly the feature our team needed. By the way, when will the feature release? |
when can we tag v2.3.4 with this change? |
I noticed that for async modules, this plugin sets "Chunks" but not "Chunk Names" (https://github.com/webpack/webpack/pull/4553/files#diff-fe6fc5dc520112c616934d9ae8a8b087). This is not the case if we use either a static |
What kind of change does this PR
feature
Did you add tests for your changes?
TBD
If relevant, link to documentation update:
TBD
Summary
based on the work of #3436
Allow chunk ids to be a string, provide NamedChunksPlugin that accepts a
name resolver
function to resolve chunks into names.This would also allow things like #2682
Does this PR introduce a breaking change?
No
Other information
Happy to add proper testing once its ok to go this direction @sokra