dreampasdsdsd 2021-04-29 10:37 采纳率: 42.9%
浏览 574
已结题

用vue-cli创建了一个新项目,运行npm run serve报错了,大神帮忙看下怎么解决

$ npm run serve

> hello-world@0.1.0 serve E:\www\hello-world
> vue-cli-service serve

 INFO  Starting development server...
 ERROR  Error: listen EAFNOSUPPORT: address family not supported 0.0.0.0:8080
Error: listen EAFNOSUPPORT: address family not supported 0.0.0.0:8080
    at Server.setupListenHandle [as _listen2] (net.js:1313:16)
    at listenInCluster (net.js:1361:12)
    at doListen (net.js:1498:7)
    at processTicksAndRejections (internal/process/task_queues.js:85:21)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! hello-world@0.1.0 serve: `vue-cli-service serve`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the hello-world@0.1.0 serve script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     C:\Users\Administrator\AppData\Roaming\npm-cache\_logs\2021-04-29T02_17_09_804Z-debug.log
 

  • 写回答

5条回答 默认 最新

  • 热心青年小邓 2021-04-29 10:45
    关注

    遇到这种问题

    首先下载个 有道词典 翻译一下什么意思,

    翻译后不会解决可以搜百度,

    百度搜不出来得话

    像是这种npm运行错误可以试一下把node_modules给删了 然后重新npm i 来安装依赖。

    记好 先翻译一下

    评论

报告相同问题?

问题事件

  • 已结题 (查看结题原因) 3月11日