Delay Removing a Class in Jquery [duplicate]

You can use setTimeout() function:

Calls a function or executes a code snippet after specified delay.

$(document).ready(function () {
   var $rows = $("#rowone.one, #rowtwo.three, #rowthree.two").addClass("pageLoad");

   setTimeout(function() {
       $rows.removeClass("pageLoad");
   }, 800);
});

Leave a Comment