问题
I'm currently working on code-splitting on CSS files on my React project. This project is built with webpack 3
, and with the help of extract-css-chunks-webpack-plugin, CSS chunks are generated nicely.
However, I found that some chunks are not loaded or imported by any JS files.
I've made a simplified project from my real project to demonstrate this issue. (here)
In this example, when the dev-server.js
is running, both app-[hash].js
and app-[contentdash].css
are loaded, while 0-[hash].js
is loaded without 0-[contentdash].css
Question is
how to get the css chunks loaded by the corresponding js chunks?来源:https://stackoverflow.com/questions/65067949/webpack-css-chunks-are-extracted-but-not-loaded-extract-css-chunks-webpack-plu