RobLoach / jquery-once

:heavy_dollar_sign: Act on jQuery elements only once.
http://npm.im/jquery-once
Other
61 stars 20 forks source link

Document preferable usage with for() instead of each() #48

Closed andypost closed 6 years ago

andypost commented 7 years ago

Or at least it makes sense to add few lines about it as suggestion

RobLoach commented 7 years ago

for()?

andypost commented 7 years ago

I mean for() loop, like https://www.drupal.org/node/1428524#comment-6163962

RobLoach commented 6 years ago

Documenting jQuery usage seems outside of the scope for jQuery Once. jQuery Once doesn't care which one you use. Could be a good blog post though! https://www.sitepoint.com/speed-question-jquery-each-vs-loop/

Perhaps there have been some good performance improvements in jQuery 3.x?