8000 fix: fix dev mode compatibility with workers (#4034) · vuejs/vue-cli@6f085d3 · GitHub
[go: up one dir, main page]

Skip to content

Commit 6f085d3

Browse files
committed
fix: fix dev mode compatibility with workers (#4034)
fixes #3539 (cherry picked from commit d81d57b)
1 parent dbac817 commit 6f085d3

File tree

1 file changed

+2
-1
lines changed
  • packages/@vue/cli-service/lib/config

1 file changed

+2
-1
lines changed

packages/@vue/cli-service/lib/config/dev.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,9 +11,10 @@ module.exports = (api, options) => {
1111
.use(require('webpack/lib/HotModuleReplacementPlugin'))
1212

1313
// https://github.com/webpack/webpack/issues/6642
14+
// https://github.com/vuejs/vue-cli/issues/3539
1415
webpackConfig
1516
.output
16-
.globalObject('this')
17+
.globalObject(`(typeof self !== 'undefined' ? self : this)`)
1718

1819
if (!process.env.VUE_CLI_TEST && options.devServer.progress !== false) {
1920
webpackConfig

0 commit comments

Comments
 (0)
0