[英]npx serve -s build -l 3000 is not working
npx serve -s build -l 3000
command to build my app in local at port 3000,命令在本地端口 3000 构建我的应用程序,
But when I ran this command it's throwing error like,但是当我运行这个命令时,它会抛出错误,例如,
await printUpdateNotification(args["--debug"]);
等待 printUpdateNotification(args["--debug"]); ^^^^^
^^^^^
SyntaxError: Unexpected reserved word at Loader.moduleStrategy (internal/modules/esm/translators.js:122:18) at async link (internal/modules/esm/module_job.js:42:21) npm ERR!
SyntaxError:在异步链接 (internal/modules/esm/module_job.js:42:21) npm ERR 处的 Loader.moduleStrategy (internal/modules/esm/translators.js:122:18) 出现意外的保留字! code ELIFECYCLE npm ERR!
代码 ELIFECYCLE npm 错误! errno 1 npm ERR!
errno 1 npm 错误! Exit status 1
退出状态 1
And in log also there is no proper error message, Can anyone suggest me the solution并且在日志中也没有正确的错误消息,任何人都可以建议我解决方案
Thanks谢谢
尝试强制安装以前版本的serve,解决我的问题
npm install serve@13.0.4
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.