Interface for working with promise objects.

For more details, read the Ajax operations documentation.


var my_promise = new webix.promise(function(success, fail){
    webix.ajax("some.php", function(text){
        if (text) success(text);
        else fail(text.error)
//realdata - data that came from server
all allows to execute a function when results from all promises are received
defer creates a new instance of a deferred object (a `promise`)
race resolves or rejects the quickest promise
reject creates and rejects a promise
resolve creates and resolves a promise with the specified value
Back to top