Back button introduction

To enable the menu to be closed by pressing the browser back button, include the "backButton" add-on .js file and use the backButton options.

<head>
   <script src="path/to/jquery.js" type="text/javascript"></script>
   <script src="path/to/jquery.mmenu.js" type="text/javascript"></script>
   <script src="path/to/jquery.mmenu.backbutton.js" type="text/javascript"></script>
   <link href="path/to/jquery.mmenu.css" type="text/css" rel="stylesheet" />
   <script type="text/javascript">
      $(document).ready(function() {
         $("#my-menu").mmenu({
            backButton: {
               // backButton options
            }
         });
      });
   </script>

Options for the "backButton" add-on

Option Default value Datatype Description
backButton A map of options or true for backButton.close.
{
close false Boolean Whether or not the menu should close when pressing the browser back button.
}

Configuration for the "backButton" add-on

The "backButton" add-on has no configuration options.

API methods for the "backButton" add-on

The "backButton" add-on has no API methods.

SCSS variables for the "backButton" add-on

The "backButton" add-on has no SCSS variables.

Dependencies:
  • Core (on-canvas + off-canvas).
Works great with:

Next add-on:
Columns