i am trying to fill a select using an array i bring from an in memory api server, but i cant make the ngfor work.
`<select materialize="material_select" [materializeSelectOptions]="tiposLocacion" id="tipo" #tipo>
<option *ngFor="let tipo from tiposLocacion" [value]="tipo.ID_TipoLocacion">{{tipo.Nombre}}
i am trying to fill a select using an array i bring from an in memory api server, but i cant make the ngfor work. `<select materialize="material_select" [materializeSelectOptions]="tiposLocacion" id="tipo" #tipo> <option *ngFor="let tipo from tiposLocacion" [value]="tipo.ID_TipoLocacion">{{tipo.Nombre}}
` thats the html. `export class NuevaLocacionComponent implements OnInit { constructor(private locacionService: LocacionService) { } tiposLocacion: TipoLocacion[]; ngOnInit() { setTimeout(() => initialize(), 300); this.locacionService.getTiposLocacion().then(tipos => this.tiposLocacion = tipos); } }`