Since my upgrading from Angular 10 to 10.1, my ivy compiler have started to misread ngFor directives.
e.g.
mat-grid-tile(
*ngFor='let preview of previewList; trackBy: trackByFn'
)
img.previews__img(
#previewImage,
)
mat-icon(
(click)='deletePreview(preview.name)',
) delete
canvas.previews__canvas(
#previewCanvas
)
.previews__name {{preview.name}}
Ivy randomly advice me:
error TS2339: Property 'preview' does not exist on type
It's trivial that preview
it's a property inside *ngFor
directive scope, but Ivy seems not understand that.
How can I solve this?
Close your running server. Start ng serve again.