Skip to content

Instantly share code, notes, and snippets.

@rajaramtt
Last active February 18, 2019 17:58
Show Gist options
  • Save rajaramtt/384d733b43d74a9ad005ebe6b5f01260 to your computer and use it in GitHub Desktop.
Save rajaramtt/384d733b43d74a9ad005ebe6b5f01260 to your computer and use it in GitHub Desktop.
Angular Life cycle
ngOnChanges Called after a bound input property changes
ngOnInit Called once the component is initialized
ngDoCheck Called during every change detection run
ngAfterContentInit Called after content (ng-content) has been projected into view
ngAfterContentChecked Called every time the projected content has been checked
ngAfterViewInit Called after the component’s view (and child views) has been initialized
ngAfterViewChecked Called every time the view (and child views) have been checked
ngOnDestroy Called once the component is about to be destroyed
ngOnChanges(changes: SimpleChanges) {
}
previousValue: any Declared in constructor.
currentValue: any Declared in constructor.
firstChange: boolean
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment