How to fix Angular 2 `Uncaught (in promise): TypeError: Cannot read property 'query' of null`?

前端 未结 6 1297
甜味超标
甜味超标 2020-12-10 03:36

I\'ve been using the Heroes tutorial in the Angular 2 docs to experiment. However, I\'ve come to a point that I don\'t understand what\'s happening with this error:

6条回答
  •  暗喜
    暗喜 (楼主)
    2020-12-10 04:29

    In the "tsconfig.json" set "emitDecoratorMetadata" parameter of the "compilerOptions" section to the "true" value.

提交回复
热议问题