title: Ionic 4 Migration : What are the Angular equivalent of Ionic 3 lifecycle events/nav guards?
body: <p>I am having a tough time doing Ionic 3 to 4 migration. The Official <a href="https://ionicframework.com/docs/building/migration#lifecycle-events" rel="noreferrer">migration guide</a> asks us to use "<em>the proper Angular alternatives</em>". Can anyone tell me the equivalent <a href="https://angular.io/guide/lifecycle-hooks#component-lifecycle-hooks-overview" rel="noreferrer">Angular lifecycle-hooks</a> replacements for the following <a href="https://ionicframework.com/docs/v3/api/navigation/NavController/" rel="noreferrer">Ionic 3 lifecycle-hooks</a>.</p>
  
  <ol>
  <li>ionViewDidLoad</li>
  <li>ionViewWillEnter [not replaced]</li>
  <li>ionViewDidEnter [not replaced]</li>
  <li>ionViewWillLeave [not replaced]</li>
  <li>ionViewDidLeave [not replaced]</li>
  <li>ionViewWillUnload</li>
  <li>ionViewCanEnter </li>
  <li>ionViewCanLeave </li>
  </ol>
  
  <p>Please help me match the above with </p>
  
  <ol>
  <li>ngOnChanges()    </li>
  <li>ngOnInit()</li>
  <li>ngDoCheck()</li>
  <li>ngAfterContentInit()</li>
  <li>ngAfterContentChecked()</li>
  <li>ngAfterViewInit()</li>
  <li>ngAfterViewChecked()    </li>
  <li>ngOnDestroy()</li>
  </ol>
  
  <p>Edit :  I have indeed gone through <a href="http://%20%20%20https://ionicframework.com/docs/api/router-outlet" rel="noreferrer">Ionic 4 router-outlet</a> docs.</p>