Reputation: 10589
Take a look at the following plunker. On the start page "foo" you can see that we have a side menu which opens by clicking the icon on the top left corner or by sliding from left side to right side.
If you now press on the "next" button to navigate to the next view "bla" you will notice that at the left upper corner a new button appears - the back button. Thats good! I want that to be like that! But i also want to be able to slide in the side menu but it is not possible. I thought when i implement a side menu it will be accessable throughout all views where i set the like the following:
angular.module("starter.bla", [])
.config(function($stateProvider, $urlRouterProvider) {
$stateProvider.state('app.bla', {
url: "/bla",
views: {
'menuContent': {
templateUrl: "bla.html"
}
}
});
});
So what is going on here? As i said i like to have the back button but i also want to be able to slide in the side menu. Until now it is just possible from the starting page.
Upvotes: 0
Views: 623
Reputation: 2486
it is there and working correctly, if add menu toggle to the bla html you can access the side menu, what i happening is the your ion-nav bar is swapping out buttons automatically so the button is just disappearing. can can just use a div and some classes like bar, bar-stable, and add and remove buttons with html code instead of a angular directive or you can add another button to open and close the menu on the top right of the bar.
<ion-view view-title="bla">
<ion-content>
<div class="card">
<button class="button button-icon" menu-toggle="left">
Bla
</button>
</div>
</ion-content>
</ion-view>
http://plnkr.co/edit/IIvBGEMdbYEFfVYrJLia?p=preview
Upvotes: 1