您的位置:首页技术文章
文章详情页

angular.js - angularjs官网Demo quickstart-master在win10系统中启动时报错

【字号: 日期:2022-10-08 11:56:38浏览:18作者:猪猪

问题描述

在cmd中npm start时报错angular.js - angularjs官网Demo quickstart-master在win10系统中启动时报错

在项目目录中的日志文件内容是:0 info it worked if it ends with ok1 verbose cli [ ’C:Program Filesnodejsnode.exe’,1 verbose cli ’C:Program Filesnodejsnode_modulesnpmbinnpm-cli.js’,1 verbose cli ’start’ ]2 info using npm@3.8.93 info using node@v6.2.04 verbose run-script [ ’prestart’, ’start’, ’poststart’ ]5 info lifecycle angular2-quickstart@1.0.0~prestart: angular2-quickstart@1.0.06 silly lifecycle angular2-quickstart@1.0.0~prestart: no script for prestart, continuing7 info lifecycle angular2-quickstart@1.0.0~start: angular2-quickstart@1.0.08 verbose lifecycle angular2-quickstart@1.0.0~start: unsafe-perm in lifecycle true9 verbose lifecycle angular2-quickstart@1.0.0~start: PATH: C:Program Filesnodejsnode_modulesnpmbinnode-gyp-bin;C:gitCodeasp.netmvcCodeasp.netmvcangularJSangularjs001node_modules.bin;C:Program Filesnodejs;C:UsersOliverAppDataRoamingnpm;C:Program Filesnodejs;C:ProgramDataOracleJavajavapath;C:Windowssystem32;C:Windows;C:WindowsSystem32Wbem;C:WindowsSystem32WindowsPowerShellv1.0;C:Program Files (x86)ATI TechnologiesATI.ACECore-Static;C:Program Files (x86)Windows Kits8.1Windows Performance Toolkit;C:Program FilesMicrosoft SQL Server110ToolsBinn;C:Program Files (x86)Microsoft SQL Server100ToolsBinn;C:Program FilesMicrosoft SQL Server100ToolsBinn;C:Program FilesMicrosoft SQL Server100DTSBinn;C:Program Files (x86)Microsoft SQL Server100ToolsBinnVSShellCommon7IDE;C:Program Files (x86)Microsoft Visual Studio 9.0Common7IDEPrivateAssemblies;C:Program Files (x86)Microsoft SQL Server100DTSBinn;C:Program FilesTortoiseSVNbin;C:Program Files (x86)Javajdk1.8.0_91binjava.exe;C:Program Files (x86)Javajdk1.8.0_91binjavac.exe;C:Program Files (x86)Javajdk1.8.0_91bin;C:Program Files (x86)Javajre1.8.0_91bin;C:Program Files (x86)Microsoft SDKsTypeScript1.0;C:Program FilesMicrosoft SQL Server120ToolsBinn;C:UsersOliver.dnxbin;C:Program FilesMicrosoft DNXDnvm;C:Program Filesnodejs;C:UsersOliverAppDataRoamingnpm10 verbose lifecycle angular2-quickstart@1.0.0~start: CWD: C:gitCodeasp.netmvcCodeasp.netmvcangularJSangularjs00111 silly lifecycle angular2-quickstart@1.0.0~start: Args: [ ’/d /s /c’,11 silly lifecycle ’tsc && concurrently 'npm run tsc:w' 'npm run lite' ’ ]12 silly lifecycle angular2-quickstart@1.0.0~start: Returned: code: 2 signal: null13 info lifecycle angular2-quickstart@1.0.0~start: Failed to exec start script14 verbose stack Error: angular2-quickstart@1.0.0 start: tsc && concurrently 'npm run tsc:w' 'npm run lite' 14 verbose stack Exit status 214 verbose stack at EventEmitter.<anonymous> (C:Program Filesnodejsnode_modulesnpmlibutilslifecycle.js:245:16)14 verbose stack at emitTwo (events.js:106:13)14 verbose stack at EventEmitter.emit (events.js:191:7)14 verbose stack at ChildProcess.<anonymous> (C:Program Filesnodejsnode_modulesnpmlibutilsspawn.js:24:14)14 verbose stack at emitTwo (events.js:106:13)14 verbose stack at ChildProcess.emit (events.js:191:7)14 verbose stack at maybeClose (internal/child_process.js:850:16)14 verbose stack at Process.ChildProcess._handle.onexit (internal/child_process.js:215:5)15 verbose pkgid angular2-quickstart@1.0.016 verbose cwd C:gitCodeasp.netmvcCodeasp.netmvcangularJSangularjs00117 error Windows_NT 10.0.1024018 error argv 'C:Program Filesnodejsnode.exe' 'C:Program Filesnodejsnode_modulesnpmbinnpm-cli.js' 'start'19 error node v6.2.020 error npm v3.8.921 error code ELIFECYCLE22 error angular2-quickstart@1.0.0 start: tsc && concurrently 'npm run tsc:w' 'npm run lite' 22 error Exit status 223 error Failed at the angular2-quickstart@1.0.0 start script ’tsc && concurrently 'npm run tsc:w' 'npm run lite' ’.23 error Make sure you have the latest version of node.js and npm installed.23 error If you do, this is most likely a problem with the angular2-quickstart package,23 error not with npm itself.23 error Tell the author that this fails on your system:23 error tsc && concurrently 'npm run tsc:w' 'npm run lite'23 error You can get information on how to open an issue for this project with:23 error npm bugs angular2-quickstart23 error Or if that isn’t available, you can get their info via:23 error npm owner ls angular2-quickstart23 error There is likely additional logging output above.24 verbose exit [ 1, true ]

问题解答

回答1:

先检查下相应的包正确安装了没 node执行下npm install -g concurrentlynpm install -g lite-servernpm install -g typescript

这样安装完还是不行的话 试试修改package.json的文件'start': 'tsc && concurrently 'npm run tsc:w' 'npm run lite' ' 改成下面这样'start': 'concurrently 'npm run tsc:w' 'npm run lite' '

回答2:

试着2楼解答问题解决,谢谢!

标签: Windows系统 win10
相关文章: