title: Can't bind function to mmenu API
body: <p>When I try binding functions to existing events from mmenu plugin API, I always encounter the following error in the developer tool at bind function: </p>
  
  <blockquote>
    <p>Uncaught TypeError: API.bind is not a function</p>
  </blockquote>
  
  <p>In my solution, I use</p>
  
  <blockquote>
    <p>jQuery mmenu v4.2.0 and
    jquery-1.12.4 </p>
  </blockquote>
  
  <p>Hereunder is my concerned code in master page. </p>
  
  <pre><code>$(document).ready(function () {
      var $menu = $("#mm-menu");
      $menu.mmenu({
          // options
      }, {
          // configuration
          offCanvas: {
              pageSelector: "#wrapper"
          }
      });
      var $icon = $("#hamburger-icon");
      var API = $menu.data("mmenu");
  
      $icon.on("click", function () {
          API.open();
      });
      API.bind('closed', function () {
          setTimeout(function () {
              $icon.removeClass("is-active");
          }, 100);
      });
  </code></pre>