Loading topic
ngOnInit exists. The earlier chapters cover those.2 min readngOnInit, the hook where most components do their startup work.2 min read@Input and template bindings. It explains why the hooks run when they do.2 min read@Input() properties work, what ngOnChanges does, and that Angular runs change detection to update templates. It also assumes basic TypeScript and RxJS knowledge.2 min readng-content, the ngOnInit hook, and basic template bindings.2 min read@ViewChild works, how change detection runs, and the difference between ngOnInit and the constructor. The AfterView hooks let you run code once Angular has created the component's template and its child components.2 min readngOnDestroy, the hook Angular calls just before it removes a component.2 min readngOnInit and ngOnDestroy work, and how to subscribe to an RxJS observable. It shows a shorter way to release resources when a component is destroyed.2 min readngOnInit and ngOnDestroy from earlier chapters. Here you put every hook into one sequence.2 min readngOnChanges, ngOnInit, ngDoCheck, the AfterContent and AfterView hooks, ngOnDestroy) and how to bind inputs. It shows how those hooks interleave when one component contains another.2 min readafterNextRender and afterRender, the hooks for DOM work that must run only in the browser.2 min readngOnChanges, ngOnInit, ngOnDestroy) and have used signal() and computed() at a basic level. It shows where signal-based code fits next to those hooks.2 min readngOnInit, ngOnDestroy, and basic RxJS subscriptions. It covers the lifecycle mistakes that show up most often and the fix for each.2 min readTestBed configures a testing module, and have read the earlier chapters on ngOnChanges, ngOnInit and ngOnDestroy. The examples use Jasmine, the Angular default. Jest's jest.spyOn works the same way.2 min read