Nav push not changing view in app component

So as the title says I have a menu on app.html, when I push with Nav I do get in the console log ionViewDidLoad but the page stays the same.

export class MyApp {
  
  @ViewChild(Nav) nav;
  rootPage:any = HomePage;
  constructor(platform: Platform, 
              statusBar: StatusBar, 
              splashScreen: SplashScreen  
              ) {
    platform.ready().then(() => {
      statusBar.show();
      splashScreen.hide();
      
      
    });
    
  }
  chat() {
    this.nav.push('ChatsPage');
  }

console log
ionViewDidLoad ChatsPage
I only get this in console log but page isn’t changing.

Are’u using lifecycle pages?

I’ve figured it out changed

<ion-nav id="nav" [root]="rootPage"></ion-nav>

to

<ion-nav id="nav" #content [root]="rootPage"></ion-nav>

1 Like