Completes animations and transitions.
If called without arguments, all animations on the screen are completed. If given an element (or selector), animations on that element and its children are completed.
Animations are completed by jumping to the last animation frame instantly. Promises returned by animation and transition functions instantly settle.
Emits the up:motion:finish event that is handled by up.animate().
Does nothing if there are no animations to complete.
A promise that fulfills when animations and transitions have finished.
Tip Your coding agent can search these docs locally with the Unpoly agent skill