报错情况
error when starting dev server:
Error: listen EACCES: permission denied 127.0.0.1:80
at Server.setupListenHandle [as _listen2] (node:net:1415:21)
at listenInCluster (node:net:1480:12)
at GetAddrInfoReqWrap.doListen [as callback] (node:net:1629:7)
at GetAddrInfoReqWrap.onlookup [as oncomplete] (node:dns:111:8)
启动项目加个端口(任意)
npm run dev -- --port 81
报错原因
文件package.json 端口80冲突
文章来源地址https://www.toymoban.com/news/detail-529247.html
"scripts": {
"dev": "vite --port 80--open", //端口80冲突
"build": "vue-tsc && vite build",
"preview": "vite preview"
},
文章来源:https://www.toymoban.com/news/detail-529247.html
到了这里,关于Vue3 启动项目失败error when starting dev server: Error: listen EACCES: permission denied 127.0.0.1:80的文章就介绍完了。如果您还想了解更多内容,请在右上角搜索TOY模板网以前的文章或继续浏览下面的相关文章,希望大家以后多多支持TOY模板网!