// app.component.html <div *ngIf="products$ | async as products"> <button *ngFor='let product of products'> {{ product.name }} </button> </div> // app.component.ts products$ = this.productService.products$; // app.service.ts products$ = this.http.get<Product[]>(this.url) .pipe( tap(console.log), catchError(this.handleError) );