已经尝试使用以下方法来实现此目标:
<ion-router-outlet swipeGesture="false" animated="false"></ion-router-outlet>
同时在 app.module 文件中:
IonicModule.forRoot({
swipeBackEnabled: false
}),
config.xml:
<preference name="AllowBackForwardNavigationGestures" value="false" />
..但是水平划动手势仍会触发导航到其他页面 :-(
我能想到和尝试过的可能方法,但部分不成功的包括:
- 以某种方式使用已弃用的ionicNavController?
- 使用hammerJS?
- 使用未记录的GestureController (https://github.com/ionic-team/ionic/tree/a77ee2a6f88e8defb1763b71e77410264fafac70/core/src/utils/gesture)
如果有人能指点正确的方向或提供如何禁用刷卡手势的示例,主要是针对iOS,我将非常高兴,非常感谢