title: Using local storage to keep sidebar's position
body: <p>I currently have a simple toggle button that collapses/expands my navigation sidebar:</p>
  
  <pre><code>&lt;div id="sidebar-wrapper" class="extend"&gt;
               &lt;button class="collapse-toggle"&gt;&lt;/button&gt;
     &lt;ul&gt;
       &lt;li&gt;&lt;/li&gt;
     &lt;/ul&gt;
  &lt;/div&gt;
  
  &lt;script type="text/javascript"&gt;
      $('.collapse-toggle').on('click', function(e) {
      $('#sidebar-wrapper').toggleClass("extend collapsed"); //you can list several class names
  
      e.preventDefault();
       });
   &lt;/script&gt;
  </code></pre>
  
  <p>I want to use local storage to remember if the menu is collapsed or open every time the user reloads.  Every local storage tutorial / answer / etc. isn't quite fitting with my <em>existing</em> javascript approach at collapsing the menu, which I'd like to keep. </p>
  
  <p>How can I make this work?  </p>