side draw menu not showing

  angular, ionic-framework

I would like to add a side draw menu but can’t get the menu to display, the hamburger icon displays but when I click it nothing happens, any ideas would be hugely appreciated.

the code for the home-page.html page where the menu should display on is:

<ion-header>
<ion-toolbar>
  <ion-title>
    Dashboard
  </ion-title>
  <ion-buttons slot="start">
    <ion-menu-button autoHide="false"></ion-menu-button>
  </ion-buttons>

</ion-toolbar>
</ion-header>

the code for the app.component.html file is:

<ion-app>
<ion-split-pane contentId="m1">
<ion-menu contentId="m1" side="start">
<ion-header>
  <ion-toolbar>
    <ion-title>Menu</ion-title>
  </ion-toolbar>
</ion-header>
<ion-content>
  <ion-list>
    <ion-item>
     <ion-label>QRCODE</ion-label>
    </ion-item>
  </ion-list>
 </ion-content>
  </ion-menu>
<ion-router-outlet id="m1"></ion-router-outlet>
</ion-split-pane>
</ion-app>

Source: Angular Questions

Leave a Reply

This site uses Akismet to reduce spam. Learn how your comment data is processed.