-
-
Notifications
You must be signed in to change notification settings - Fork 211
CSS modules not works with PostCSS (Webpack 2) #129
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
Comments
@azat-io Could you try PostCSS common config? |
@ai Yes. All works good if I put list of plugins to |
Seems like we have a mystery issue in webpack 2. I have no idea how to fix it and just will force a common config. |
Okay 😞 |
If you worry about too many config files, just put PostCSS plugins in Or help me with debugging 😆 |
Also you could try |
this work for me. hope it is helpful |
This worked for me webpack-contrib/css-loader#413 (comment) |
It's strange and looks like a bug 🐛
I'm using Webpack v.2.1.0-beta.25
If I add CSS modules to
css-loader
afterpostcss-loader
the same class names which imports from different.jsx
files will have the same hash.If I remove
postcss-loader
and settings for PostCSS all will works good.This is not plugin problem.
Look here please: https://github.com/azat-io/webpack2-css-modules-demo
At this repo you can see three different components which contains
.title
class name. If you try to build app you can see that all of this classes will have the same hash.After then just comment
postcss-loader
and settings fornew webpack.LoaderOptionsPlugin
and all will works good.Previous issue
The text was updated successfully, but these errors were encountered: