title: Ionic 2 : How to check current page is root page in Ionic 2?
body: <p>I just want to check current page name in Ionic 2 for that I have used NavController in app.component.ts, but this giving an error that <strong>No provider for NavController</strong>. Please suggest me some solution, Thanks in advance.</p>
  
  <p>This is My Code below :</p>
  
  <pre><code>constructor(platform: Platform,public alertCtrl: AlertController,public navControll:NavController) {
      this.platform=platform;
      //this.nav=nav;
      platform.ready().then(()=&gt;{
       if(navControll.canGoBack())
       {
           platform.registerBackButtonAction(()=&gt;this.myHandlerFunction());
       }  
        StatusBar.styleDefault();
        Splashscreen.hide();
  })
  }
  </code></pre>