7

My ionic side menu is working in android mobile but in ios i am not getting.

here is the code for .html

<button ion-button menuToggle icon-only class="menuButton"> 
  <ion-icon name="menu"></ion-icon>
</button>

<ion-menu [content]="mycontent">
  <ion-content>
    <ion-list>
      <p>some menu content, could be list items</p>
    </ion-list>
  </ion-content>
</ion-menu>

<ion-nav #mycontent ></ion-nav>

i dont understand where is my issue is if you need anything please let me know

my side menu is working in android and browser except ios

Suraj Rao
  • 29,388
  • 11
  • 94
  • 103
Mohan Gopi
  • 7,606
  • 17
  • 66
  • 117

2 Answers2

27

Try adding type="overlay" to the sidemenu:

<ion-menu [content]="mycontent" type="overlay">
Thomas
  • 2,375
  • 2
  • 17
  • 32
2

use click function instead of menuToggle

<button ion-button icon-only start (click)="openSideMenu()">
     <ion-icon name="md-menu"></ion-icon>
</button>

open menu using

openSideMenu() {
   this.menuCtrl.enable(true)
    this.menuCtrl.toggle();    
}

disable menu before you push to new page

this.menuCtrl.enable(false)
PRATHYUSH P
  • 175
  • 1
  • 5