Navbars can utilize .navbar-toggler
, .navbar-collapse
, and .navbar-expand-lg-{sm|md|lg|xl}
classes to change when their content collapses behind a button. In combination with other utilities, you can easily choose when to show or hide particular elements.
For navbars that never collapse, add the .navbar-expand-lg
class on the navbar. For navbars that always collapse, don’t add any .navbar-expand-lg
class.