javascript - Comma-separated jQuery selectors performance -


please advise way using selectors in jquery faster:

$('.class1, .class2').html(''); 

or

$('.class1').html(''); $('.class2').html(''); 

in terms performance seems same(7-8%), in terms of maintainability first method better since there no duplication of code


Comments

Popular posts from this blog

c++ - Creating new partition disk winapi -

Android Prevent Bluetooth Pairing Dialog -

VBA function to include CDATA -