Weird behavior with sidebar+routing

Hey! I’m probably doing something wrong here, but I’m having a really weird behavior with sidebar and routing.

  • Slide to open sidebar
  • Click link
  • The screen doesn’t go ‘focus’ on the next page (the sidebar doesn’t close)
  • Also, the back button isn’t available :frowning:

From what I see you most probably have something like this in your side menu:

<li>
  <a href="#/sideMenu/profile" class="item item-icon-left">
    <i class="icon ion-person"></i>Profile
  </a>
</li>

Try adding menu-close nav-clear attribute directives to your <a/> tag:

<li>
  <a href="#/sideMenu/profile" class="item item-icon-left" menu-close nav-clear>
    <i class="icon ion-person"></i>Profile
  </a>
</li>

menu-close and nav-clear docs

1 Like

Just so you know navClear was removed in beta 14. Using just menuClose will accomplish what navClear did. :smile:

2 Likes

Hey @pcbulai and @brandyshea thanks for the info!

1 Like