When I view my website on mobile, though the hamburger menu appears, it doesn't respond after clicking. I am not sure what's wrong with my code.
<nav class="navbar navbar-expand-lg navbar-light bg-light">
<a class="navbar-brand wc" href="">our association</a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="list" aria-controls="navbarSupportedContent" aria-expanded="false" aria-label="Toggle navigation">
<span class="navbar-toggler-icon"></span>
</button>
<div class="collapse navbar-collapse" id="navbarNav">
<ul class="navbar-nav">
<li class="nav-item">
<a class="nav-link wc navb-it" href="">About</a>
</li>
<li class="nav-item">
<a class="nav-link wc dropbtn navb-it" href="#">stuff1</a>
</li>
<li class="nav-item">
<a class="nav-link wc navb-it" href="#">stuff2</a>
</li>
<li class="nav-item dropdown">
<a class="nav-link dropdown-toggle wc navb-it" href="#" id="navbarDropdown">Event</a>
<div class="dropdown-menu mt-0" aria-labelledby="navbarDropdown">
<a class="dropdown-item" href="#">2020 Hackathon</a>
<a class="dropdown-item" href="#">Coding Challenges</a>
</li>
</ul>
<ul class="navbar-nav ml-auto">
<li class="nav-item">
<a class="nav-link wc navb-it" href="">Log in</a>
</li>
<li class="nav-item">
<a class="nav-link wc navb-it" href="">Register</a>
</li>
</ul>
</div>
</nav>
At the beginning it didn't appear at all, that was because I didn't add a bootstrap color scheme to the navbar. Now, even though it shows, the menu bar in the mobile view doesn't work when clicking. Thank you.
Aucun commentaire:
Enregistrer un commentaire