Cannot read property 'webpackHotUpdate' of undefined
See original GitHub issueVersion
3.4.0
Environment info
System:
OS: Windows 7
CPU: (4) x64 Intel(R) Core(TM) i7-6500U CPU @ 2.50GHz
Binaries:
Node: 8.12.0 - C:\nodejs\node.EXE
Yarn: 1.13.0 - C:\Program Files (x86)\Yarn\bin\yarn.CMD
npm: 5.7.1 - C:\nodejs\npm.CMD
npmPackages:
@vue/babel-helper-vue-jsx-merge-props: 1.0.0-beta.2
@vue/babel-plugin-transform-vue-jsx: 1.0.0-beta.2
@vue/babel-preset-app: 3.3.0
@vue/babel-preset-jsx: 1.0.0-beta.2
@vue/babel-sugar-functional-vue: 1.0.0-beta.2
@vue/babel-sugar-inject-h: 1.0.0-beta.2
@vue/babel-sugar-v-model: 1.0.0-beta.2
@vue/babel-sugar-v-on: 1.0.0-beta.2
@vue/cli-overlay: 3.3.0
@vue/cli-plugin-babel: ^3.0.1 => 3.3.0
@vue/cli-plugin-e2e-nightwatch: ^3.0.1 => 3.3.0
@vue/cli-plugin-eslint: ^3.0.1 => 3.3.0
@vue/cli-plugin-pwa: ^3.2.0 => 3.3.0
@vue/cli-plugin-unit-mocha: ^3.0.1 => 3.3.0
@vue/cli-service: ^3.0.1 => 3.3.1
@vue/cli-shared-utils: 3.3.0
@vue/component-compiler-utils: 2.5.1
@vue/eslint-config-airbnb: ^3.0.1 => 3.0.5
@vue/preload-webpack-plugin: 1.1.0
@vue/test-utils: ^1.0.0-beta.20 => 1.0.0-beta.28
@vue/web-component-wrapper: 1.2.0
babel-helper-vue-jsx-merge-props: 2.0.3
babel-plugin-transform-vue-jsx: 4.0.1
eslint-plugin-vue: 4.7.1
vue: ^2.5.17 => 2.5.22
vue-chat-scroll: ^1.3.3 => 1.3.5
vue-eslint-parser: 2.0.3
vue-gesture: ^2.0.0 => 2.0.0
vue-hot-reload-api: 2.3.1
vue-i18n: ^8.3.0 => 8.7.0
vue-loader: 15.6.1
vue-moment: ^4.0.0 => 4.0.0
vue-multi-select: ^3.11.1 => 3.11.1
vue-multiselect: ^2.1.3 => 2.1.3
vue-qrcode-reader: ^1.3.0 => 1.3.4
vue-router: ^3.0.1 => 3.0.2
vue-router-prefetch: ^1.2.0 => 1.2.0
vue-slider-component: ^2.7.8 => 2.8.6
vue-spinner: ^1.0.3 => 1.0.3
vue-style-loader: 4.1.2
vue-template-compiler: ^2.5.17 => 2.5.22
vue-template-es2015-compiler: 1.8.2
vue-toasted: ^1.1.26 => 1.1.26
vue2-touch-events: ^1.0.0 => 1.1.2
vuejs-datepicker: ^1.5.4 => 1.5.4
vuex: ^3.0.1 => 3.1.0
npmGlobalPackages:
@vue/cli: Not Found
Steps to reproduce
using --modern on build i got this error.
What is expected?
using --modern i can run the module version of the project
What is actually happening?
error because is using [this] and got undefined. the error seems that is a problem on HMR webapack plugin but with default configuration on vue-cli, in production should be disabled
Issue Analytics
- State:
- Created 5 years ago
- Reactions:2
- Comments:5 (1 by maintainers)
Top Results From Across the Web
Cannot read property 'webpackHotUpdate' of undefined ...
The core issue is that "this" should be "self" for webpages (as opposed to node). The webpack.config.js should not be:
Read more >gaearon/react-hot-loader - Gitter
Hi guys, I'm using redux and I set up webpack hot loader plugin. ... bundle.js:30 Uncaught TypeError: Cannot read property 'webpackHotUpdate' of undefined....
Read more >Webpack HMR breaks after manual refresh - Roots Discourse
Uncaught ReferenceError: webpackHotUpdate is not defined · Issue ... Uncaught TypeError: Cannot set properties of undefined (setting '.
Read more >rewiremock - npm
Rewiremock provides lots of APIs to help you set up mocks, ... TypeError: Cannot read property 'webpackHotUpdate' of undefined.
Read more >Hot Module Replacement - webpack
If you know of any other loaders or plugins that help with or enhance HMR, please submit a pull request to add them...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
The issue is caused by
@vue/cli-service
package. It is fixed in version 3.8.0Had the same thing for a second. Reason being we had forgotten
NODE_ENV=
in our.env
file so the bundle wasn’t build in a production mode. 🤦♂️ Hope this helps out some dummies like me in the future.