How to make *ngFor work with an ObservableArray in Nativescript?


An ObservableArray works fine with <ListView [items]=“feedsComments”, where feedsComments is an ObservableArrayin NativeScript.

But when I replace the ListView with the following:

<StackLayout *ngFor=“let item of feedsComments”>

It throws the following error:

ERROR Error: Cannot find a differ supporting object ‘[object Object],[object Object]’ of type ‘object’.
NgFor only supports binding to Iterables such as Arrays.