I am working with multiple arrays of objects in my typescript file and I need to simultaneously iterate through them to display their contents in the HTML file. The arrays are always the same size, making it easier to work with. Here is what I currently have:
<ion-item>
{{array1[i]}} {{array2[i]}} {{array3[i]}}
</ion-item>
My initial attempt at using ngFor for the iteration encountered an error: "Can't bind 'ngForIn' since it isn't a known property of 'ion-item'. I then tried a workaround which didn’t seem very elegant:
<ion-item *ngFor="let counter of array1; let i = index">
{{array1[i]}} {{array2[i]}} {{array3[i]}}
</ion-item>
If you have any suggestions on how to improve this process or if there’s a cleaner way to achieve the desired result, I would greatly appreciate it :)
Thank you!