-
Notifications
You must be signed in to change notification settings - Fork 2.3k
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
Styles optimization is not applied when using Webpack 5 #6816
Comments
Update: I have upgraded the project to 12.8.0, and I have removed tailwind to avoid any external factors. Now using only randomly generated css. I have pushed the changes to the repo (link in my previous comment). Still experiencing the same problem, css is not minified with wepback 5. |
I have tested with nx 12.9.0 and the css is still not minified in production build. |
ISSUES CLOSED: nrwl#6816
This issue has been closed for more than 30 days. If this issue is still occuring, please open a new issue with more recent context. |
Current Behavior
The output CSS is not minified when running the production build with webpack 5.
Expected Behavior
The CSS should be minified when using
--prod
orNODE_ENV=production
. The minification works with webpack 4.Steps to Reproduce
No, because that's using webpack 4. However, upgrading to webpack 5 would highlight the problem.
I have created a project to reproduce the problem: https://github.com/markogresak/nx-styles-bug#reproducing-the-css-minification-problem
It's a project where I've added only some randomly generated css to the output.
Failure Logs
As you can see, the output is not minified.
Environment
The text was updated successfully, but these errors were encountered: