Beware of premature optimization
Bear in mind that optimization on a certain level degrades readability and maintenability of your code so you should only resort to such measures when there is an absolute need to do so. In 99% of all cases this won't be necessary because you just don't need the few milliseconds saving. If you are in dire need of extra performance you should first reconsider the general design of your code and check for real bottlenecks such as overly use of abstractions that slow things down ($() for instance).
Comments are closed