Heroku npm ERR! app@0.0.0 postinstall:`ng build --prod --aot`

时间:2017-11-13 20:47:54

标签: node.js angular heroku

我试图将我的angular + nodeJS应用程序推送到heroku但我无法部署它。我已经尝试了100多种东西和组合。

这是错误消息:

27.0.1

这是package.json文件。我把所有角度都从devDependencies移开,只是为了试图看看它是否可以修复错误,但它没有帮助。

remote:        > app@0.0.0 postinstall /tmp/build_cef68857f715f26620e2e4f29fab803f
remote:        > ng build --prod --aot
remote:
remote:        /tmp/build_cef68857f715f26620e2e4f29fab803f/node_modules/@angular/cli/models/config/config.js:76
remote:        throw new InvalidConfigError(common_tags_1.stripIndent `
remote:        ^
remote:
remote:        InvalidConfigError: Parsing '/tmp/build_cef68857f715f26620e2e4f29fab803f/.angular-cli.json' failed. Ensure the file is valid JSON.
remote:        Error: Unexpected token / in JSON at position 493
remote:        at Function.fromConfigPath (/tmp/build_cef68857f715f26620e2e4f29fab803f/node_modules/@angular/cli/models/config/config.js:76:19)
remote:        at Function.fromProject (/tmp/build_cef68857f715f26620e2e4f29fab803f/node_modules/@angular/cli/models/config.js:88:46)
remote:        at Object.<anonymous> (/tmp/build_cef68857f715f26620e2e4f29fab803f/node_modules/@angular/cli/commands/build.js:7:35)
remote:        at Module._compile (module.js:571:32)
remote:        at Object.Module._extensions..js (module.js:580:10)
remote:        at Module.load (module.js:488:32)
remote:        at tryModuleLoad (module.js:447:12)
remote:        at Function.Module._load (module.js:439:3)
remote:        at Module.require (module.js:498:17)
remote:        at require (internal/module.js:20:19)
remote:        npm ERR! code ELIFECYCLE
remote:        npm ERR! errno 1
remote:        npm ERR! app@0.0.0 postinstall: `ng build --prod --aot`
remote:        npm ERR! Exit status 1
remote:        npm ERR!
remote:        npm ERR! Failed at the app@0.0.0 postinstall script.
remote:        npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
remote:
remote:        npm ERR! A complete log of this run can be found in:
remote:        npm ERR!     /app/.npm/_logs/2017-11-13T20_41_32_365Z-debug.log

有关触发此错误的内容以及如何解决此问题的任何建议?

0 个答案:

没有答案