Now that we can add a new entry to the developers' collection, let's show a list of all the developers on the front page of the "Coders repository."
Open the ch7/step-1/home.ts file (or step-2, depending on your progress during the past section), and enter the following content:
import {Component} from '@angular/core'; import {DeveloperCollection} from './developer_collection'; @Component({ selector: 'home', templateUrl: './home.html' }) export class Home { constructor(private developers: DeveloperCollection) {} getDevelopers() { return this.developers.getAll(); } }
There is nothing new to us here. We extend the functionality of the Home component by providing an external template and implementing the getDevelopers method, which delegates its call to the instance...