Ionic 2.0.0-beta.7 nav push page


#1

Good evening
I’m updating my application to the ionic 7 beta I followed the migration tutorial and my imports are:

import {provide,ViewChild} from '@angular/core';
import {App, IonicApp,NavController,Platform,MenuController} from 'ionic-angular';
import {StatusBar,Splashscreen} from 'ionic-native';
import {Http, Headers} from '@angular/http';
import {Home} from './pages/home/home';
import {Contact} from './pages/contact/contact';
import {TranslateService, TranslatePipe, TranslateLoader, TranslateStaticLoader} from 'ng2-translate/ng2-translate';

and use ViewChild like this:

queries: {
nav: new ViewChild(‘content’)
}
That is my open page function:
openPage(page) {
this.nav.setRoot(page);
}
when I run the application I get the following error:
EXCEPTION: Error in :0:0app.bundle.js (ligne 33943)
ORIGINAL EXCEPTION: TypeError: this.nav is undefinedapp.bundle.js (ligne 33943)ORIGINAL STACKTRACE:
please help :smile: