Animation can be a bit of a hassle with jQuery, especially when you want to chain an animation and another action (such as removing the element from the DOM). The animation can often get missed out in the sequence of events.

The key to solving this is to use jQuery’s queue()functionality.

Here’s a quick demonstration:

 

Matt Reid

Lead Software Architect. Java/Node enthusiast, badminton lover, foodie.

drei01 Matthew_Reid


Published