Angular 2 Service Two-Way Data Binding
I have a salary.service and a player.component , if the salary variable gets updated in the service will the view in the player component be updated? Or is that not the case in Angular 2? When the page first loads I see the 50000 in the player.component view, so I know the two are working together. It's updating the value that's has me stumped. salary.service export class SalaryService { public salary = 50000; // starting value which gets subtracted from constructor() { } public setSalary = (value) => { this.salary = this.salary - value }; } player.component export class PlayerComponent {