The API is a little confusing because animate returns a reference to the element to enable chaining. But you can do this:
animate
$element.animate(...); $element.promise().then(function() { ... });