Comment on Don’t use IDs in CSS selectors? (2011)parentComments−josephscott11yI did not know this before, very interesting.Despite the easy access as a global variable, using document.getElementById() turns out to still be faster - http://jsperf.com/id-vs-class-vs-tag-selectors/328
Comments
I did not know this before, very interesting.
Despite the easy access as a global variable, using document.getElementById() turns out to still be faster - http://jsperf.com/id-vs-class-vs-tag-selectors/328