-
Notifications
You must be signed in to change notification settings - Fork 805
-
Notifications
You must be signed in to change notification settings - Fork 805
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
请教一个有关build/webpack.dev.conf.js的配置问题 #92
Comments
你说的是这一段吗 module.exports = merge(baseWebpackConfig, {
module: {
rules: utils.styleLoaders({ sourceMap: config.dev.cssSourceMap })
},
// cheap-module-eval-source-map is faster for development
devtool: '#cheap-module-eval-source-map',
plugins: [
new webpack.DefinePlugin({
'process.env': config.dev.env
}),
// https://github.com/glenjamin/webpack-hot-middleware#installation--usage
new webpack.HotModuleReplacementPlugin(),
new webpack.NoEmitOnErrorsPlugin(),
// https://github.com/ampedandwired/html-webpack-plugin
new HtmlWebpackPlugin({
filename: 'index.html',
template: 'index.html',
inject: true
}),
new FriendlyErrorsPlugin()
]
}) 这个Merge函数就是引入的 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
vue-cli默认生成的的此文件中会在合并webpack.base.conf.js配置时引入
module: {
rules: utils.styleLoaders({sourceMap: config.dev.cssSourceMap})
}
如果我在使用这个配置的时候会爆Module build failed的Error,但如果参照你的文件删除这个配置,问题就解决了,按照文档上来说这项配置是定义“配置样式文件的处理规则的styleLoaders”,是不是在此文件中配置这个module会把webpack.base.conf.js中的此项配置给覆盖掉?
The text was updated successfully, but these errors were encountered: