fix: revert node-externals disabling in dev mode (#5452)

This commit is contained in:
Xin Du (Clark) 2019-04-03 10:44:36 +01:00 committed by Pooya Parsa
parent 913069ff59
commit 6ce99d2cc8

View File

@ -109,7 +109,7 @@ export default class WebpackServerConfig extends WebpackBaseConfig {
// https://webpack.js.org/configuration/externals/#externals // https://webpack.js.org/configuration/externals/#externals
// https://github.com/liady/webpack-node-externals // https://github.com/liady/webpack-node-externals
// https://vue-loader.vuejs.org/migrating.html#ssr-externals // https://vue-loader.vuejs.org/migrating.html#ssr-externals
if (!this.dev && !this.buildContext.buildOptions.standalone) { if (!this.buildContext.buildOptions.standalone) {
this.buildContext.options.modulesDir.forEach((dir) => { this.buildContext.options.modulesDir.forEach((dir) => {
if (fs.existsSync(dir)) { if (fs.existsSync(dir)) {
config.externals.push( config.externals.push(