Search
 
SCRIPT & CODE EXAMPLE
 

JAVASCRIPT

javascript auto hide navbar

$(window).click(function(e) {

    if($(".navbar-collapse").hasClass("show")){
       $('.navbar-collapse').removeClass("show"); 
       e.preventDefault();
       }
});
 
$('.navbar-collapse').click(function(event){
      event.stopPropagation();
});

// use 'navbar-collapse' on your navbar
Comment

PREVIOUS NEXT
Code Example
Javascript :: toggle boolean js 
Javascript :: convert string to camel case 
Javascript :: js array clone 
Javascript :: add query parameter to url react router v6 
Javascript :: javascript in keyword 
Javascript :: javascript split sentence into words 
Javascript :: react native backgrunde img 
Javascript :: unfocus javascript 
Javascript :: how to add seconds to time in js 
Javascript :: checkbox set checked jquery 
Javascript :: PayloadTooLargeError 
Javascript :: npm add latest version to package json 
Javascript :: loading image in react js 
Javascript :: To use the new parser, pass option { useNewUrlParser: true } to MongoClient.connect 
Javascript :: server.js 
Javascript :: A <Route is only ever to be used as the child of <Routes element, never rendered directly. Please wrap your <Route in a <Routes. 
Javascript :: foreach over array javascript 
Javascript :: unique element in array 
Javascript :: how to get on click id in event 
Javascript :: clear value input jquery 
Javascript :: javascript calculate percentage to pixel 
Javascript :: switch case in javascript 
Javascript :: percentage formula in javascript 
Javascript :: discord.js emoji in embed 
Javascript :: hashing in node js 
Javascript :: remove specific element from array javascript 
Javascript :: javascript object to query string 
Javascript :: javascript if object has key 
Javascript :: how to get thumbnail image from video file in javascript 
Javascript :: string concatenation javascript 
ADD CONTENT
Topic
Content
Source link
Name
8+6 =