Hi guys, for some days I've got a question about usage of scope inside jquery iterators like each.
Do you really think that referring to current item using "this" is a good thing? I think it's limitation for who use jquery in object oriented approach. I think it will be better passing current item to closure as an arguments... $("div").each(function(div, index) { console.log(div); //current item console.log(index); //current index console.log(this); // window or custom scope }); -- everything has got to end sometime we were satellites drifting off into space vega 4 - burn and fade away --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "jQuery Development" group. To post to this group, send email to jquery-dev@googlegroups.com To unsubscribe from this group, send email to jquery-dev+unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/jquery-dev?hl=en -~----------~----~----~----~------~----~------~--~---