I am using asynchronous functions in my JS application wrapped with my own functions that receive callback inputs. When i call the callback function, do I need to use the "return" keyword? does it matter? whats the difference?
eg:
var getData = function(callback){
// do some aysnc db stuff...
return callback(results);
// or just
callback(results);
}
PS: I am writing a hybrid mobile appiliction using javascript.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…