Molunerfinn / vue-koa-demo

:beginner:A simple full stack demo(CSR & SSR & Docker Support) written by Vue2 & Koa2(Koa1 verson also completed)
MIT License
756 stars 166 forks source link

ssr webpack-hot-middleware error #45

Closed Braveheartforyou closed 5 years ago

Braveheartforyou commented 5 years ago

node -v v11.10.0 npm -v 6.7.0 "webpack-dev-middleware": "^1.12.0", "webpack-hot-middleware": "^2.18.2" yarn server or npm run server f5 刷新頁面 D:***\node_modules\webpack-hot-middleware\middleware.js:104 if (!res.finished) res.end(); ^

TypeError: res.end is not a function at IncomingMessage. (D:\work\dfrc-front\node_modules\webpack-hot-middleware\middleware.js:104:32) at IncomingMessage.emit (events.js:197:13) at abortIncoming (_http_server.js:451:9) at socketOnEnd (_http_server.js:466:5) at Socket.emit (events.js:202:15) at endReadableNT (_stream_readable.js:1129:12) at processTicksAndRejections (internal/process/next_tick.js:76:17) [nodemon] app crashed - waiting for file changes before starting...

Molunerfinn commented 5 years ago

It's not the vue-koa-demo's error. You should check the webpack-hot-middleware.

Braveheartforyou commented 5 years ago

那怎么解决呢?你有遇到过吗?

Molunerfinn commented 5 years ago

没有。这个仓库Vue相关的代码比较老了,建议用vue-cli重新搭一个

RQAccount commented 5 years ago

这个问题解决了吗,遇到同样的问题

huangshengyi commented 5 years ago

你好,这个问题你最终怎么解决呀,我webpack3.x搭建的项目没问题,升到4.x现在也遇到这问题 --- koa搭的脚手架