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
fix(react): fix extracCss option for webpack 5 #6925
Conversation
This pull request is being automatically deployed with Vercel (learn more). 🔍 Inspect: https://vercel.com/nrwl/nx-dev/3M1iipM963fwxpB5irgSnwTD7Xtj [Deployment for d3aaa6e canceled] |
38f7919
to
8fe845d
Compare
Nx Cloud ReportCI ran the following commands for commit d3aaa6e. Click to see the status, the terminal output, and the build insights. 📂 See all runs for this branch Sent with 💌 from NxCloud. |
|
||
export class NamedLazyChunksPlugin { | ||
constructor() {} | ||
apply(compiler: Compiler): void { | ||
// Webpack doesn't export these so the deep imports can potentially break. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Had to move it here since later versions of webpack 5 doesn't have these modules anymore, causing the build to break.
8fe845d
to
0017dc1
Compare
0017dc1
to
aaeb6d5
Compare
aaeb6d5
to
d3aaa6e
Compare
This pull request has already been merged/closed. If you experience issues related to these changes, please open a new issue referencing this pull request. |
This PR fixes a configuration issue with CSS extraction. There shouldn't be a split chunks configuration since we want to keep it all in one file.
Current Behavior
When using webpack 5 and the CSS gets too large it'll split into multiple chunks, and the generated
index.html
is missing styling.Expected Behavior
Everything should work the same as before in webpack 4.
Related Issue(s)
Fixes #6819, #6664, #6558, #6816