我试图strictNullChecks
在 Angular 4 应用程序中实现。
我刚刚添加 "strictNullChecks": true
了tsconfig.json
当我运行应用程序时ng serve
,出现以下错误。
ERROR in [at-loader] ./node_modules/@angular/forms/src/model.d.ts:244:39
TS2459: Type '{ onlySelf?: boolean | undefined; emitEvent?: boolean |
undefined; } | undefined' has no property 'emitEvent' and no string index signature.
怎么了?我们如何
strictNullChecks
在 Angular 4 中实现?