JSFiddle - React, Tailwind, and code Playground
by Mark Coleman
HTML
<div>With Queue</div>
<div>No Queue</div>
<input type="button" value="Reset"/>
CSS
div{
background-color:red;
}
JavaScript
$(":button").click(function(){
$("div").css("width", "").css("height", "");
});
$("div:first").click(function() {
$(this).animate({
width: 100
}, {
duration: 1000
}).animate({
height: 200
}, {
duration: 2000
});
});
$("div:last").click(function() {
$(this).animate({
width: 100
}, {
duration: 1000,
queue: false
}).animate({
height: 200
}, {
duration: 2000,
queue: false
});
});