When does the back button show?


I would like to know what are the scenarios where back buttons actually appear.

I have these states :

.state('categories', {
    url: '/categories',
    templateUrl: 'templates/categories.html'

  .state('categories.posts', {
    url: '/:CategoryId',
    views: {
      'categories-posts': {
        templateUrl: 'templates/categories-posts.html',
        controller: 'CatPostsCtrl'

Where I display posts belonging to a given category.

Then I have these states:

.state('posts', {
    abstract: true,
    url: '/posts',
    templateUrl: 'templates/posts.html'
  .state('posts.details', {
    url: '/:PostId',
    views: {
      'posts-details': {
        templateUrl: 'templates/posts-details.html',
        controller: 'PostsCtrl'

That displays the post once clicked on from the list of posts displayed in the category.

What I want is a back button from the post details to the post list inside the category.

Is it naturally achievable or should I hack the button myself?

Thank you.


Have you included the correct directive:

  <!-- The nav bar that will be updated as we navigate -->
  <ion-nav-bar class="bar-positive">
    <ion-nav-back-button class="button-clear">
      <i class="ion-arrow-left-c"></i> Back

Here’s my Master-Detail pattern example: http://plnkr.co/edit/NN4cWr?p=info


in index.html I have this:

<ion-nav-bar class="bar-stable bar-positive">

Also you’re not transiting from nested states with both different abstract parents? Is that a thing?


I figured out the problem,
it’s this code:

<ion-tabs class="tabs-icon-top tabs-color-active-positive">

    <!-- Dashboard Tab -->
    <ion-tab title="Status" icon-off="ion-ios-pulse" icon-on="ion-ios-pulse-strong" ui-sref="home">
        <ion-nav-view name="categories-posts"></ion-nav-view>


apparently the tabs screw the history or don’t even use them