title: Collapsing Sidebar with Bootstrap
body: <p>I just visited this page <a href="https://web.archive.org/web/20131015001517/https://www.elmastudio.de/" rel="noreferrer">http://www.elmastudio.de/</a> and wondered if it is possible to build the left sidebar collapse with Bootstrap 3.</p>
  
  <p>Code to collapse the sidebar from the top (phone only):</p>
  
  <pre class="lang-html prettyprint-override"><code>&lt;button type="button" class="navbar-toggle sidebar-toggle" data-toggle="collapse" data-target=".sidebar-ex1-collapse"&gt;
      &lt;span class="sr-only"&gt;Sidebar&lt;/span&gt;
      &lt;span class="glyphicon glyphicon-check"&gt;&lt;/span&gt;
  &lt;/button&gt;
  </code></pre>
  
  <p>Sidebar itself has the hidden-xs class. It is removed with the following js</p>
  
  <pre class="lang-js prettyprint-override"><code>$('.sidebar-toggle').click(function(){
       $('#sidebar').removeClass('hidden-xs');            
  });
  </code></pre>
  
  <p>If you click the button it toggles the sidebar from the top. It be great to see the sidebar behave like the website above shows. Any help is appreciated!</p>