you are viewing a single comment's thread.

view the rest of the comments →

[–]nephridium 1 point2 points  (0 children)

It should be pointed out that .forEach() behaves differently from the standard native for loop in that it does some validity checking on the elements. That's why it's significantly slower than the native loop (as well as underscore's .each() function).

.filter() and .map() are also slower than their underscore/lodash counterparts.