title: Ionic 4 : ngOnInit vs ionViewWillEnter
body: <p>Which is better to use Angular Lifecycle Hook or Ionic Lifecycle hooks specially for initialization when creating a hybrid app using Ionic 4?</p>
  
  <p>Angular lifecycle hook - ngOnInit </p>
  
  <pre><code>ngOnInit() {
      this.getData();
  }
  </code></pre>
  
  <p>Ionic lifecycle hook - ionViewWillEnter </p>
  
  <pre><code>ionViewWillEnter() {
      this.getData();
  }
  </code></pre>