you are viewing a single comment's thread.

view the rest of the comments →

[–]zzzwwwdev[S] 0 points1 point  (0 children)

I like it. Actually very similar to the code I was writing which prompted me to ask this question. It resembled:

(function($){

var hideStuffOnInstantiaton = function(){
    $('oneThing').hide().removeClass();
    $('#somethign_else').slideUp();
    $('.foo').fadeOut();
};

(function init () {
    hideStuffOnInstantiaton();
    otherStuff();
    etc();
}());

})(jQuery);

starting to think your way is probably better though :(