Passing params in the SinglePromise Component methods like 'then' and 'done'
andru255 opened this issue · 2 comments
andru255 commented
The proposal is for SinglePromise Component when invoke the 'done' method passing a value and using after on the callback 'then' like a param:
var fnUsingSinglePromise = function(){
var objSinglePromise = new yOSON.Components.SinglePromise();
var instanceToPassing = "valueToPassWhenItsDone";
objSinglePromise.done(instanceToPassing);
return objSinglePromise;
};
fnUsingSinglePromise.then(function(instancePassingWhenItsDone){
//Do some with the instancePassingWhenItsDone param
});
jansanchez commented
👍
jansanchez commented
👍