The performance difference is shown here.
Should I use jQuery("#id")
or jQuery(document.getElementById("id"))
?
Should I change all of my uses of jQuery("#id")
to document.getElementById("id")
because of the performance difference?
I prefer jQuery("#id")
because it is easier to read and consistent with the CSS selector.