angular-seed: AOT compilation not working

Hello! Thanks for this seed, it is super helpful. I am having an issue with the “compile.ahead.prod” task which is failing to execute. Just a few days ago this was working for a different project. Today I started a new project by recloning the seed and the AOT proces is failing. I troubleshot it for most of the day but I am fairly new to Angular 2 and Typescript.

Steps to reproduce and a minimal demo of the problem

  1. clone the current angular2-seed repo
  2. Execute ‘npm install’ , then ‘npm run build.prod.exp’
  3. You get this error: Error: undefined, resolving symbol ApplicationModule in {myinstallfolder}/angular2-seed/node_modules/@angular/core/src/application_module.d.ts at simplifyInContext (C:\Users\iminar\Dev\angular\modules\@angular\compiler-cli\src\static_reflector.ts:528:15) at StaticReflector.simplify (C:\Users\iminar\Dev\angular\modules\@angular\compiler-cli\src\static_reflector.ts:532:18) at StaticReflector.annotations (C:\Users\iminar\Dev\angular\modules\@angular\compiler-cli\src\static_reflector.ts:92:28) at _loop_1 (C:\Users\iminar\Dev\angular\modules\@angular\compiler-cli\src\codegen.ts:63:48) at CodeGenerator.readFileMetadata (C:\Users\iminar\Dev\angular\modules\@angular\compiler-cli\src\codegen.ts:57:22) at C:\Users\iminar\Dev\angular\modules\@angular\compiler-cli\src\codegen.ts:105:56 at Array.map (native) at CodeGenerator.codegen (C:\Users\iminar\Dev\angular\modules\@angular\compiler-cli\src\codegen.ts:105:33) at codegen ({myinstallfolder}\angular2-seed\tools\tasks\seed\compile.ahead.prod.ts:14:69) at Object.main ({myinstallfolder}\tools\@angular\tsc-wrapped\src\main.ts:44:12) Compilation failed

Other information Attached the npm debug log: npm-debug.txt

Thank you for any help you can give me

About this issue

  • Original URL
  • State: closed
  • Created 8 years ago
  • Comments: 18 (7 by maintainers)

Most upvoted comments

Thank you all for your suggestions. In case it helps someone in the future, I was able to fix my issue in Wndows with a combo of two things:

  • Upgrading node to v6.7.0 (it seems to work on anything 6.5.0+ )
  • Removing this PATH from my environment variables C:\Program Files (x86)\Microsoft SDKs\TypeScript\1.0\ - it got added with an old TypeScript pluging for Visual Studio 2013

just had the same problem, found this issue, updated tsc from 1.8x to 2.0x … no it works!