4: Add Services
[examples/angular-tour-of-heroes] / src / app / hero.service.ts
index d0801f3..8df8f33 100644 (file)
@@ -13,6 +13,7 @@ export class HeroService {
   constructor(private messageService : MessageService) { }
 
   getHeroes() : Observable<Hero[]> {
+    this.messageService.add('HeroService: fetching heroes...');
     return of(HEROES);
   }
 }