all

resolves all promises in the resulting array

array all(array promises);

Parameters

promisesarrayan array of 'promise' objects to resolve

Returns

arraya resulting promise

Example

a = webix.ajax("someA.php");
b = webix.ajax("someB.php");
c = webix.ajax("someC.php");
 
 
webix.promise.all([ a,b,c ]).then(function(results){
    var a_result = results[0];
    var b_result = results[1];
    var c_result = results[2];
    // do something
});

Details

The function is executed when callbacks are received from all of the requests for which 'promise' objects have been passed into the function.

Back to top