ionic笔记
经验:
  1.隐藏导航的返回按钮(hideBackButton)<ion-navbar hideBackButton="true">
  

   2.重写导航返回按钮的点击事件

·  import { Navbar } from 'ionic-angular';

   export class OrientationStudentDormOrderPage {

    @ViewChild(Navbar) navBar: Navbar;

    constructor(public navCtrl: NavController) { }

    ionViewDidLoad() {
      this.navBar.backButtonClick = (e: UIEvent) => {
      this.navCtrl.popToRoot();
    }
    }

  

posted on 2019-07-16 16:30  dbolodb  阅读(81)  评论(0编辑  收藏  举报