Home › Forums › JavaScript › Add/remove class by jquery › Reply To: Add/remove class by jquery
October 22, 2014 at 8:20 am
#186823
__
Participant
setTimeout
is a native javascript function, not a jQuery method. This means you couldn’t chain it with your other jQuery methods:
setTimeout( function(){
$( ‘.header-menu’).addClass(‘shadow-menu’);
},1000);
But I suspect that you could simply put .addClass
after .delay
(i.e., without using .queue
/.dequeue
at all).