You need to sign in to do that
Don't have an account?
Arut Jothi
$A.getCallback()
1) What are some of scenarios where $A.getCallback can be used other than using setTimeout function??
2) Does it make sense to place $A.getCallback inside a Promise constructor while calling a server side controller action? For example, see below
return new Promise($A.getCallback(function(resolve, reject){
// Implement the code logic here to call a server side controller
}));
2) Does it make sense to place $A.getCallback inside a Promise constructor while calling a server side controller action? For example, see below
return new Promise($A.getCallback(function(resolve, reject){
// Implement the code logic here to call a server side controller
}));
Refer this link
https://rajvakati.com/2018/05/29/using-promise-in-lightning-component/
Thanks for the response but you are taling about using Promises in a Lightning component. My question is rather different and very specific to using $A.getCallback while implementing promises in a Lightning component.
This is one major use of $A.getCallback(say Aura.getCallback) that I have found.