gpt4 book ai didi

node.js - Angular2 - Windows 7 上的 npm 启动错误

转载 作者:太空宇宙 更新时间:2023-11-03 17:09:42 28 4
gpt4 key购买 nike

我是 angular 的新手,我一直在努力学习更多关于 angular2 的知识。我按照入门指南创建了 angular2-quickstart 项目。但是,当我运行命令 npm start 时,浏览器启动但 1 秒后一切都失败了。以下是我的 npm 错误日志文件的内容:

ramesh@ramesh-PC MINGW32 /c/Projects/quickstart (master)
$ node --version
v7.4.0

ramesh@ramesh-PC MINGW32 /c/Projects/quickstart (master)
$ npm --version
4.1.1

$ npm start

> angular-quickstart@1.0.0 start C:\Projects\quickstart
> tsc && concurrently "tsc -w" "lite-server"

node_modules_rr/karma/config.tpl.ts(13,18): error TS1109: Expression expected.
node_modules_rr/karma/config.tpl.ts(13,30): error TS1109: Expression expected.
node_modules_rr/karma/config.tpl.ts(17,13): error TS1109: Expression expected.
node_modules_rr/karma/config.tpl.ts(18,5): error TS1109: Expression expected.
node_modules_rr/karma/config.tpl.ts(22,15): error TS1109: Expression expected.
node_modules_rr/karma/config.tpl.ts(23,5): error TS1109: Expression expected.
node_modules_rr/karma/config.tpl.ts(28,20): error TS1109: Expression expected.
node_modules_rr/karma/config.tpl.ts(28,35): error TS1109: Expression expected.
node_modules_rr/karma/config.tpl.ts(51,16): error TS1109: Expression expected.
node_modules_rr/karma/config.tpl.ts(51,28): error TS1109: Expression expected.
node_modules_rr/karma/config.tpl.ts(56,16): error TS1109: Expression expected.
node_modules_rr/karma/config.tpl.ts(56,26): error TS1109: Expression expected.

npm ERR! Windows_NT 6.1.7600
npm ERR! argv "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\ramesh\\AppData\\Roaming\\npm\\node_modules\\npm\\bin\\npm-cli.js" "start"
npm ERR! node v7.4.0
npm ERR! npm v4.1.1
npm ERR! code ELIFECYCLE
npm ERR! angular-quickstart@1.0.0 start: `tsc && concurrently "tsc -w" "lite-server" `
npm ERR! Exit status 2
npm ERR!
npm ERR! Failed at the angular-quickstart@1.0.0 start script 'tsc && concurrently "tsc -w" "lite-server" '.
npm ERR! Make sure you have the latest version of node.js and npm installed.
npm ERR! If you do, this is most likely a problem with the angular-quickstart package,
npm ERR! not with npm itself.
npm ERR! Tell the author that this fails on your system:
npm ERR! tsc && concurrently "tsc -w" "lite-server"
npm ERR! You can get information on how to open an issue for this project with:
npm ERR! npm bugs angular-quickstart
npm ERR! Or if that isn't available, you can get their info via:
npm ERR! npm owner ls angular-quickstart
npm ERR! There is likely additional logging output above.

npm ERR! Please include the following file with any support request:
npm ERR! C:\Projects\quickstart\npm-debug.log

谢谢。

最佳答案

尝试

npm cache clean
npm install

关于node.js - Angular2 - Windows 7 上的 npm 启动错误,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/41873043/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com