Having two interfaces, Response and Info, where Response includes an array and object. Using the ASYNC Pipe, I aim to display data from a provided URL. The Result is in Array format and Info is an Object. However, when trying to display the value of Info, I encounter the following error:
**Error TS2322: Type 'Info' is not assignable to type 'NgIterable | null | undefined'.**
**Model Interface**
interface Response {results: Result[];info: Info; }
interface Result { gender: string; email: string;}
interface Info { seed: string;results: number;}
**TS**
customerObs = this.http.get<Response>('https://randomuser.me/api/?format=json');
constructor(private http: HttpClient) { }
HTML
<ul *ngIf="customerObs | async as response">
<li *ngFor="let result of response.results">{{result.gender}}</li>
<li *ngFor="let info of response.info">{{info.seed}}
</ul>