diff --git a/packages/webpack/src/config/server.js b/packages/webpack/src/config/server.js index 25a30c37f4..eb72b24f9b 100644 --- a/packages/webpack/src/config/server.js +++ b/packages/webpack/src/config/server.js @@ -28,6 +28,13 @@ export default class WebpackServerConfig extends WebpackBaseConfig { whitelist.push(new RegExp(escapeRegExp(posixModule))) } } + + // Bundle vue js for avoiding single shared Vue instance + const { runInNewContext } = this.buildContext.options.render.bundleRenderer + if (runInNewContext === true) { + whitelist.push('vue') + } + return whitelist }