Promise object constructor
executor | function | a callback used to initialize the promise |
object | the promise object |
new scheduler.Promise(function(resolve, reject) {
setTimeout(function(){
resolve();
}, 5000);
}).then(function(){
alert("Resolved")
});
The Promise object constructor.