在我的React项目中,我想激活CSS模块,我运行了eject,但不知道在哪里将模块设置为"true“,因为我似乎找不到"webpack.config.dev.js"enter image description here
发布于 2019-06-05 19:14:14
我想您正在使用CRA。CSS模块开箱即用(无需弹出)。在webpack.config.js中,您可以找到const cssModuleRegex = /\.module\.css$/;和const sassModuleRegex = /\.module\.(scss|sass)$/;。有关更多信息,请查看CRA -> https://facebook.github.io/create-react-app/docs/adding-a-css-modules-stylesheet的文档
https://stackoverflow.com/questions/56459222
复制相似问题