Template is:
<tr *ngFor="let row of rows; let i = index">
<div (click)=""edit(row)></div>
</tr>
Component is:
public edit(row: PostAddress): void {
dialogRef.afterClosed().subscribe((postaddress) => {
if (postaddress) {
row = postaddress;
this._change.markForCheck();
}
}
I see that variable was chnaged on a new value: row = postaddress;
but template does not render.
I use changeDetection: ChangeDetectionStrategy.OnPush
Also I have tried this:
row = postaddress;
this._change.markForCheck();
this._change.detectChanges();