I use animate.css to create an animation. If an error occurs, the element should bounce:
$target.addClass('animated bounce');
It works well. But if the user does the same, there will be no second animation, since classes have already been added.
So, I am trying to remove the classes after the animation as follows:
$target.addClass('animated bounce');
setTimeout(function(){
$target.removeClass('animated bounce');
}, 1000);
My question is: if so, how should it be done (I don’t know how long the animation is for exactly), or is there another solution for repeating the animations?
source
share