Navigation is used in Bootstrap to share general markup and styles by using base class base.nav. The base components in navigation are built with flexbox which helps to make multiple types of navigation components.
The syntax is shown below:
<nav class=” ”> <a class=” ”href=” “></a> </nav>
Aligned nav: Nav can be aligned by using justify-content class either horizontally or vertically.
Base nav: It provides a strong foundation for all types of navigation components and its component does not have an active state.
Tabs: It create tabs in the navigation bar by using the .nav-tab class.
Pills: Navs can be turned into pills by using the .nav-pills class.
All navs have different nav-items. In code, different types of navs are used like:
Let’s look at the code below:
In the above code, we create
html file and add 4
navs in it.
View all Courses