-
Notifications
You must be signed in to change notification settings - Fork 6
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
Webpack 4 - DeprecationWarning: Chunk.mapModules #17
Comments
Hey, thanks for your interest. Reason I'm asking: It was created as workaround to shortcomings of webpack@2, and webpack@3 should have addressed that issues. Thank you. |
So, this is a good question as I can't particularly remember why I've kept using it, but only that it was consistent in producing the same hashes across builds, and even today it seems to do so, where Webpack does not. I removed this plugin as a test and it seems intermittent that I get different chunkhash's across builds. I'm not sure if that's related to webpack/webpack#6623, which is fairly recent, but without the webpack-chunk-hash plugin, I'll get vendor files (using CommonChunk) named like follows: vendor.717d59f0f1b557550a73.js Interestingly enough, the main entry point always seems to be consistent. I am using the NamedModulesPlugin, according to the best practices of these articles, 1 & 2, to ensure consistent filenames across builds, so I'm not sure where the discrepancy is actually happening. Alternatively, using the webpack-chunk-hash, I consistently get a vendor file named: Functionally, I don't really understand when Webpack is generating that chunkhash or what it's actually using to create a hash, but if I were to take an educated guess, I assume it's not on the input of the code and rather on some form of the output which any number of plugins or loaders could change. |
Yeah, we're seeing the same thing, inconsistent hashing in webpack 4, though this module fixes it for us. We'd love to continue using this with webpack 4, thanks for working on a fix! |
I'm seeing the same error, is this fixed now? |
@anthonybrown This should be fixed in 0.6.0. If you see the same error, add stack traces when running webpack with node the node trace-deprecation flag, i.e. |
Webpack 4 is complaining of a deprecation warning:
I believe it relates to this particular line. Hopefully I can get around to a PR for this.
The text was updated successfully, but these errors were encountered: