It basicly a wrapper around Promises.
Nothing of your sync functions work until after you do syncify.revert which gives you a function taking a CALLBACK.
Nothing of your sync functions work until after you do syncify.revert which gives you a function taking a CALLBACK.
function getFullName( id ){ return ajax( "/user/" + id + "/name" ) + " " + ajax( "/user/" + id + "/lastname" ) }
How does it know to to wait for both ajax functions before returning the correct value? Am I misunderstanding something?