Sunday, March 12, 2017

Cannot find name 'Promise'

This error, upon compiling TypeScript, is happening for me because I have something in my node_modules folder that is "too new" which can happen if you just set requirements to get version X or better of things. The or better part stops working. If you have an old copy of your node_modules folder, you might try to rollback to it. My problem seems to stem from @angular/core being greater than version 2.4.6 or zone.js being greater than version 0.7.6, because I have an old folder full of the node_modules dependencies with these settings and that old folder works just fine. Use these commands in PowerShell to check what version of zone.js and rxjs you are using:

  • npm ls zone.js
  • npm ls rxjs

No comments:

Post a Comment