I tried the following code:
@Component({ selector: 'test-content', template: ' <div *ngIf="sv.name.notExist.testUndefined != undefined"> {{sv.name.notExist.testUndefined}} ', directives: [FORM_DIRECTIVES] })
The variable sv.name.notExist.testUndefined is undefined, but I check it with * ngIf and the result is an error message: "TypeError: it is not possible to read the testUndefined property from undefined in [sv.name.notExist.testUndefined! = Undefined in ... "
Please help me check the undefined variable on * ngIf.
source share