electron-vue icon indicating copy to clipboard operation
electron-vue copied to clipboard

GET http://localhost :9080/__ webpack_ hmr 404 (Not Found)

Open cazure opened this issue 4 years ago • 4 comments
trafficstars

Found an issue or bug with electron-vue

After using the command to create a project, execute the command to install the package normally, and let it run after debugging without modifying any code. The console in the developer tool always prompts

GET http://localhost :9080/__ webpack_ hmr net::ERR_ ABORTED GET http://localhost :9080/__ webpack_ hmr 404 (Not Found)

在使用命令创建项目后,正常的执行命令安装包,让后运行调试,没有修改任何代码。 开发者工具里面的console一直提示 GET http://localhost:9080/__webpack_hmr net::ERR_ABORTED GET http://localhost:9080/__webpack_hmr 404 (Not Found)

  • Node version:8.9.3
  • NPM version: 6.14.8
  • vue-cli version: (if necessary)
  • Operating System:win7 64

"dependencies": { "axios": "^0.18.0", "element-ui": "^2.15.1", "vue": "^2.5.16", "vue-electron": "^1.0.6", "vue-router": "^3.0.1", "vuex": "^3.0.1", "vuex-electron": "^1.0.0" }, "devDependencies": { "ajv": "^6.5.0", "babel-core": "^6.26.3", "babel-loader": "^7.1.4", "babel-plugin-transform-runtime": "^6.23.0", "babel-preset-env": "^1.7.0", "babel-preset-stage-0": "^6.24.1", "babel-register": "^6.26.0", "babel-minify-webpack-plugin": "^0.3.1", "cfonts": "^2.1.2", "chalk": "^2.4.1", "copy-webpack-plugin": "^4.5.1", "cross-env": "^5.1.6", "css-loader": "^0.28.11", "del": "^3.0.0", "devtron": "^1.4.0", "electron": "^2.0.4", "electron-debug": "^1.5.0", "electron-devtools-installer": "^2.2.4", "electron-builder": "^20.19.2", "mini-css-extract-plugin": "0.4.0", "file-loader": "^1.1.11", "html-webpack-plugin": "^3.2.0", "listr": "^0.14.3", "node-loader": "^0.6.0", "node-sass": "^4.9.2", "sass-loader": "^7.0.3", "style-loader": "^0.21.0", "url-loader": "^1.0.1", "vue-html-loader": "^1.2.4", "vue-loader": "^15.2.4", "vue-style-loader": "^4.1.0", "vue-template-compiler": "^2.5.16", "webpack-cli": "^3.0.8", "webpack": "^4.15.1", "webpack-dev-server": "^3.1.4", "webpack-hot-middleware": "^2.22.2", "webpack-merge": "^4.1.3" }

cazure avatar May 06 '21 02:05 cazure

same question! have some solutions?

feixierman avatar May 13 '21 09:05 feixierman

Turn off the hot option of WebpackDevServer this file in .electron-vue/dev-runner.js line:67

`
const server = new WebpackDevServer(

compiler,

{

contentBase: path.join(__dirname, '../'),

quiet: true,

//hot: true,

before (app, ctx) {

app.use(hotMiddleware)

ctx.middleware.waitUntilValid(() => {

resolve()

})

}

}

)

server.listen(9080) `

cazure avatar May 13 '21 09:05 cazure

I followed your advice and still get an error. Is there any other solution?

image

colinder avatar Aug 24 '21 06:08 colinder

Just uncomment this line in dev.runner.js file

app.use(hotMiddleware)

thestrangedev avatar Sep 10 '21 12:09 thestrangedev