安装问题 Angular
Problems installing Angular
我在全局安装 Angular 时遇到问题。我在下面包含了错误。
C:\Users\DevSa\ng -> C:\Users\DevSa\node_modules\@angular\cli\bin\ng
> @angular/cli@8.3.19 postinstall C:\Users\DevSa\node_modules\@angular\cli
> node ./bin/postinstall/script.js
'node' is not recognized as an internal or external command,
operable program or batch file.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @angular/cli@8.3.19 postinstall: `node ./bin/postinstall/script.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the @angular/cli@8.3.19 postinstall 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\DevSa\AppData\Roaming\npm-cache\_logs19-11-26T21_34_00_712Z-debug.log
在环境变量 PATH 列表的顶部添加 C:\Program Files\nodejs\
,然后在其下方添加 C:\Users\{your username}\AppData\Roaming\npm
。
希望能解决您的问题。
我在全局安装 Angular 时遇到问题。我在下面包含了错误。
C:\Users\DevSa\ng -> C:\Users\DevSa\node_modules\@angular\cli\bin\ng
> @angular/cli@8.3.19 postinstall C:\Users\DevSa\node_modules\@angular\cli
> node ./bin/postinstall/script.js
'node' is not recognized as an internal or external command,
operable program or batch file.
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! @angular/cli@8.3.19 postinstall: `node ./bin/postinstall/script.js`
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the @angular/cli@8.3.19 postinstall 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\DevSa\AppData\Roaming\npm-cache\_logs19-11-26T21_34_00_712Z-debug.log
在环境变量 PATH 列表的顶部添加 C:\Program Files\nodejs\
,然后在其下方添加 C:\Users\{your username}\AppData\Roaming\npm
。
希望能解决您的问题。