Here’s what you need to know before getting started with the navbar:
.navbar
with .navbar-expand{-sm|-md|-lg|-xl|-xxl}
for responsive collapsing and color scheme classes.<nav>
element or, if using a more generic element such as a <div>
, add a role="navigation"
to every navbar to explicitly identify it as a landmark region for users of assistive technologies.aria-current="page"
for the current page or aria-current="true"
for the current item in a set.Theming the navbar has never been easier thanks to the combination of theming classes and background-color
utilities. Choose from .navbar-light
for use with light background colors, or .navbar-dark
for dark background colors. Then, customize with .bg-*
utilities.