navbar toggler collapse not working

Clash Royale CLAN TAG#URR8PPP
navbar toggler collapse not working
On clicking the button, the content drops down but it does not collapse on clicking the button again. Basically the toggle function isn't working.
<button type="button" class="navbar-toggle collapsed"
data-toggle="collapse" data-target="#collapsable" aria- expanded="false">
<div class="collapse navbar-collapse" id="collapsable">
<ul class="nav navbar-nav navbar-right">
<li><a href="#particles">HOME</a></li>
<li><a href="#service">EVENTS</a></li>
<li><a href="#about">About</a></li>
<li><a href="#team">FACULTY ADVISORS</a></li>
<li><a href="#portfolio">OUR TEAM</a></li>
<li><a href="#contact">CONTACT</a></li>
</ul>
</div>
It's not clear whether you want to build a navbar with toggler or just a button to trigger collapsible div? getbootstrap.com/docs/4.1/components/navbar/#toggler or getbootstrap.com/docs/4.1/components/collapse?
– David Liang
Aug 12 at 7:18
im building a navbar with toggler
– Sriharsh Aditya
Aug 12 at 12:19
Post all of the relevant code to repro the issue. The code you've provided isn't a properly structure Navbar and the HTML is invalid. For example, the button has no content and close tag.
– Themes.guide
Aug 12 at 13:15
2 Answers
2
If your navbar collapse is not working then there must be some error with the js or css so upload them too
ive used bootstrap dude
– Sriharsh Aditya
Aug 12 at 12:22
One thing to note is that there’s a space in the middle of aria-expanded when there shouldn’t be. That may be causing the html to be malformed. Though without seeing the JS, it’s near impossible to diagnose the problem.
By clicking "Post Your Answer", you acknowledge that you have read our updated terms of service, privacy policy and cookie policy, and that your continued use of the website is subject to these policies.
Please post relevant CSS and JavaScript along with your example.
– Michael Kolber
Aug 12 at 5:17