What i'm trying to do might sound simple.
I just need to make a callback with another function Here is an example using jQuery.
(function ( $ ) {
"use strict";
var colors;
colors = function(col){
return col;
};
$(document).ready(function(){
colors(function(){alert('Orange');});
});
})(jQuery);
So when the document be ready, i need to send an alert that says 'Orange' but i want to do it by returning a function.
If you know another way to do it please let me know.
alert()function.