you can use async pipe, you dont have to subscribe to your Observable,
component.ts:
export class FormationsComponent {
formations: Observable<Formation[]>;
constructor(private formationService: FormationService){};
ngOnInit() {
this.formations = this.formationService.getFormations();
}
}
and in your html file
<tr *ngFor="let formation of formations | async" >
0
solved Angular 2 *ngFor does not print to table , I am getting my information from a GET HTTP call and it works