Glide.js execute script after API rewind is executed

I did setup a rail with Glide.js
I need to rewind it and then execute some other code but I don’t know how to stop my script untile rewind is completed

I did try with jQuery when since it returns an object but doesn’t seems to work

$.when( glideInstance.go('<<') ).done(function( e ) {
   alert("execute code");
});