Returns a promise so that you can uses promises to track when a tween or timeline is complete.
Version:
GreenSock Docs
Timeline
.then()
.then( callback:Function ) : Promise
Returns a promise so that you can uses promises to track when a tween or timeline is complete.
Parameters
callback: Function
The function that you want to handle the Timeline's promise that is generated.
Returns : Promise

Details
Some people prefer to use Promises instead of onComplete
callbacks. You can now tag on a then()
call to the end of any tween or timeline that’ll return a Promise
.
gsap.timeline.to(".class", {duration: 1, x: 100}).then(yourFunction).then(...);