我正在使用 react-bootstrap 和 css 模块。在我的 webpack.config.js 中,我可以使用以下配置运行我的 bootstrap.css:
{ test: /\.css$/, loader: "style-loader!css-loader" }
但是我的 css 模块应该有这个设置:
{
test: /\.css$/,
loaders: [
'style?sourceMap',
'css?modules&importLoaders=1&localIdentName=[path]___[name]__[local]___[hash:base64:5]'
]
}
如何将它们结合起来以使其适用于 css 模块和 react-bootstrap