Back button disappearing on tab views


#1

Hi there,

I have a quite strange issue that I wondered if anyone could help me with.

I have a tab view with 5 tabs, if i perform a series of view changes, the back button randomly disappears.

The issue also happens on this codepen. https://codepen.io/ionic/pen/VLwLOG

If you perform the following steps, it can be reproduced
tab 1 -> subview -> back
tab 2 -> subview -> back
tab 1 -> subview -> back
tab 2 -> subview

On this subview, there is no back button.

Any help is appreciated.


#2

I encounter the same problem too. In fact I can replicate the bug in the ionic documentation page:

http://ionicframework.com/docs/api/directive/ionTabs/

Try:

home -> scientific facts -> back
about -> tabs nav stack -> back
home -> scientific facts -> back
about -> tabs nav stack


ionViewDidLoad called each time tab is clicked
#3

Any workaround to this? Incredible this is happening on ionic sample code


#4

I had faced the same issue and I have used below workaround. It works for me.

I have used ionic example
http://ionicframework.com/docs/api/directive/ionTabs/

//Add new controller for NavStack
.state(‘tabs.navstack’, {
url: “/navstack”,
views: {
‘about-tab’: {
templateUrl: “templates/nav-stack.html”,
controller: ‘NavStackCtrl’
}
}
})

//In controller add below code
.controller(‘NavStackCtrl’, function($scope,$ionicNavBarDelegate,$ionicHistory) {
$ionicHistory.nextViewOptions({
disableBack: true
});
$ionicNavBarDelegate.showBackButton(true);
});

//Codepen Edit


#5

Try this workaround. I have created new controller.


#6

It also has the same issue, on home the back is lost


#7

I’m unable to replicate the issue, could you tell me the steps.


#8

Maybe this behaviour is related to the following issue: