我正在使用Angular4和Angular / CLI 1.2.1 . 我能初始化很好并使用ng服务在本地运行应用程序 . 然而,在推送到远程git仓库然后在不同的机器上拉下我的工作后 - 我得到错误 .

Steps to Recreate
1.从远程git repo中拉出使用Angular CLI创建的项目 .
2. NPM安装 .
3.服务 .

Error Messages

D:/application/src/app/app.component.ts中的错误(1,27):找不到模块'@ angular / core' . D:/application/src/app/app.component.ts中的错误(8,14):对装饰器的实验支持是一个在将来的版本中可能会发生变化的功能 . 设置'experimentalDecorators'选项以删除此警告 . 错误在D:/application/src/app/app.module.ts(1,31):找不到模块'@ angular / platform-browser' . D:/application/src/app/app.module.ts中的错误(2,26):找不到模块'@ angular / core' . 错误在D:/application/src/app/app.module.ts(16,14):对装饰器的实验支持是一个在将来的版本中可能会发生变化的功能 . 设置'experimentalDecorators'选项以删除此警告 . D:/application/src/main.ts中的错误(1,32):找不到模块'@ angular / core' . D:/application/src/main.ts中的错误(2,40):找不到模块'@ angular / platform-browser-dynamic' . ERROR in无法在D中解析模块@ angular / core ERROR:/application/src/main.ts(1,32):找不到模块'@ angular / core' . D:/application/src/main.ts中的错误(2,40):找不到模块'@ angular / platform-browser-dynamic' . 错误在D:/application/src/app/app.module.ts(1,31):找不到模块'@ angular / platform-browser' . D:/application/src/app/app.module.ts中的错误(2,26):找不到模块'@ angular / core' . 错误在D:/application/src/app/app.module.ts(16,14):对装饰器的实验支持是一个在将来的版本中可能会发生变化的功能 . 设置'experimentalDecorators'选项以删除此警告 . D中的错误:/application/src/app/app.component.ts(2,27):找不到模块'@ angular / core' . D:/application/src/app/app.component.ts中的错误(8,14):对装饰器的实验支持是一个在将来的版本中可能会发生变化的功能 . 设置'experimentalDecorators'选项以删除此警告 . webpack:编译失败 .

NPM Install Output

npm WARN首选全局node-gyp@3.6.2应与-g一起安装

node-sass@4.5.3安装D:\ application \ node_modules \ node-sass node scripts / install.js

在C:\ Users \ user \ AppData \ Roaming \ npm-cache \ node-sass \ 4.5.3 \ win32-x64-48_binding.node中找到缓存的二进制文件

node-sass@4.5.3 postinstall D:\ application \ node_modules \ node-sass node scripts / build.js

二进制文件位于D:\ application \ node_modules \ node-sass \ vendor \ win32-x64-48 \ binding.node测试二进制二进制文件很好

...继续安装没有错误(包括@ angular / core和其他包) .