🔔 Alert..!! Get 2 Month Free Cloud Hosting With $200 Bonus From Digital Ocean ACTIVATE DEAL

Responsive-collapse.js is a jQuery plugin that automatically hides overflowing Bootstrap navbar items and shows them into a dropdown list on small screens.

Bootstrap responsive-menu

Documentation

A jQuery plugin for partially collapsing Bootstrap navbars.

Installation

Include script after the jQuery library (unless you are packaging scripts somehow else):

<script src="/path/to/bootstrap.responsive-collapse.js"></script>

Do not include the script directly from GitHub (http://raw.github.com/...). The file is being served as text/plain and as such being blocked in Internet Explorer on Windows 7 for instance (because of the wrong MIME type). Bottom line: GitHub is not a CDN.

Usage

$('.navbar-nav').responsiveCollapse();

Customization

$('.navbar-nav').responsiveCollapse({ 	// Bootstraps xs breakpoint 	breakPoint: 768,  	// Content for overflow menu item 	overflowItemText: '<i class="fa fa-bars"></i> More <b class="caret"></b>' });

Authors

Donald Becker


You May Also Like