OK so in jQuery;
I have a selecter $("#gmap")
I want to do alot of code in context of my selector. I have always been lazy and used .each() even though there is only one of them.
$("#gmap321654987789").each(function(){
$(this).....
});
Is this particuarly effitiant? I hate code that doesn’t feel ‘right’.
Is there a mechanism for say… or something similar.
$("#gmap321654987789").this(function(){
$(this).....
});
Just cache the object and work with it like normal: