The Author Online Book Forums are Moving

The Author Online Book Forums will soon redirect to Manning's liveBook and liveVideo. All book forum content will migrate to liveBook's discussion forum and all video forum content will migrate to liveVideo. Log in to liveBook or liveVideo with your Manning credentials to join the discussion!

Thank you for your engagement in the AoF over the years! We look forward to offering you a more enhanced forum experience.

welkie (26) [Avatar] Offline
#1
In this section the code provided for the Dashboard component is out of date. The GitHub repo has the correct code, but the book has this code:

@Component({
selector: 'app-dashboard',
templateUrl: './dashboard.component.html',
styleUrls: ['./dashboard.component.css']
})
export class DashboardComponent implements OnInit {
stocks: Array<StockInterface>;
symbols: Array<string>;

constructor(private service: StocksService) {
this.symbols = service.get();
}

ngOnInit() {
this.subscription = this.service.load(this.symbols).subscribe(stocks => this.stocks = stocks);
}
}

"this.subscription = " causes an error since that property of the class doesn't exist.
jeremy.wilken (208) [Avatar] Offline
#2
Thanks for the report, I'll update it.