Skip to content
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

Hashing Issue. Changing styles cause invalidate script hash #117

Closed
mishelen opened this issue Apr 30, 2018 · 2 comments
Closed

Hashing Issue. Changing styles cause invalidate script hash #117

mishelen opened this issue Apr 30, 2018 · 2 comments

Comments

@mishelen
Copy link

mishelen commented Apr 30, 2018

maybe I'm not in the right place writing. But the situation is that after migration to Webpack 4 I had to change the style extractor to mini-css-extract-plugin from extract-text-webpack-plugin. From now on hashing began not to work properly: if I change styles, the hash of entry scripts changes, but if I change scripts, the hash of styles does not change.

I use the same settings as I did with webpack 3. Then I studied the problem length and breadth. Solving is simple:

output: {
        filename: '[name].[chunkhash].js'
},
plugins: [
        new webpack.HashedModuleIdsPlugin(),
        new ExtractCSS({
            filename: '[name].[contenthash].css'
        })
]

+ extract runtime chunk aka manifest

But now I dont have any glue.
I'm just created repo with this issue: https://github.com/mishelen/reproduce_hash_invalidation webpack settings are in config folder

ubuntu 16.04.04
node v8.11.1
used packages version

@alexander-akait
Copy link
Member

@mishelen yes, it is bug, not in plugin, inside webpack. Ref webpack/webpack#7138. Thanks for issue

@mishelen
Copy link
Author

@evilebottnawi Thank you. It remains only to add +1 to the specified issue and add a reference to my repo

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

No branches or pull requests

2 participants