This is how I wrap all my JavaScript:
;(function($, window, undefined) {
var document = window.document;
var myFunction = function() {}
})(jQuery, window);
But now I have the need to call myFunction from outside of that closure.
window.addEventListener("offline", function(e) {
myFunction();
}, false);
Q: How do I name the self executing anonymous function so that I can call myFunction from the global scope?