Feature: add compiler output options support for hash #120
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Good day, guys!
Yesterday I worked on configuring webpack for my own project and I found that I can't use the same output filename settings for all loaders. Especially, for file-loader.
Here is the part of webpack.config.js:
After compilation I found that the hash part of name of extracted css and bundled files are truncated, but all other assets that I uploaded as is with file-loader are not truncated. As solution, I should pass
maxLength
tooptions.name
(in format[name].[hash:8].[ext]
) and it will work as I expected.I think it is not good because I should pass the same settings for each loader, maybe is better to support compiler settings as it support MiniCssExtractPlugin.
What you think about it?