DEV Community

Cover image for UPDATED: Bootstrap v5.0.2 Navbar with Multi-Level and Mega Menu
Simon Köhler
Simon Köhler

Posted on

UPDATED: Bootstrap v5.0.2 Navbar with Multi-Level and Mega Menu

In February 2021, I published this article: "Bootstrap v5 Navbar Component with Multi-Level and Mega Menu".

https://dev.to/typo3freelancer/bootstrap-v5-navbar-component-with-multi-level-and-mega-menu-1218

Due to the many requests, I just rebuilt the pen to make the example compatible for Bootstrap 5.0.2.

No more custom JavaScript required!

The JavaScript is completely dropped thanks to the new features in Bootstrap. You can create arbitrary dropdown menus with infinite levels using the "data-bs-auto-close" attributes and "data-bs-toggle", as well as the "dropend" and "dropstart" classes.

Top comments (3)

Collapse
 
stoevno1 profile image
stoevno1

One thing everyone was probably waiting for a very long time. I am glad it's finally here.

Collapse
 
typo3freelancer profile image
Simon Köhler

Yes, the new Bootstrap Dropdown functionality is more than awesome. Just als modals and offcanvas ;)

Collapse
 
benjaminv profile image
benjaminv

Very neat.