I'm developing an Ionic 2 Android application. I want to know how can I hide the control button on the bottom ("← O 口") as well as the title bar on the top?
可以将文章内容翻译成中文,广告屏蔽插件可能会导致该功能失效(如失效,请关闭广告屏蔽插件后再试):
问题:
回答1:
According to this question, we can hide the status bar in Ionic 2 using the following code:
import {StatusBar} from 'ionic-native';
import {App, Platform} from 'ionic-angular';
//He wrotes 'ionic/ionic', but it doesn't work for me.
constructor(private platform: Platform) {
this.platform.ready().then(()=>{
StatusBar.hide();
}
}