by pixl8ed · 13y ago · 0 comments
In $(".widget").css("color", "green").css("font-size", "16px"); does the color of all the widgets change, and then the fontSize, or does the color/fontSize change together for each widget? I suspect the latter...
[0] https://github.com/jquery/jquery/blob/master/src/css.js#L102
[1] https://github.com/jquery/jquery/blob/master/src/css.js#L103
[2] https://github.com/jquery/jquery/blob/master/src/core.js#L75...
[3] https://github.com/jquery/jquery/blob/master/src/core.js#L75...
There is no extra DOM lookups, but there will certainly be two loops.