99% of the time I see usage of Array.prototype.some and Array.prototype.reduce, it would have been much more readable with a manual loop.
-
-
@raganwald Familiarity has a lot to do with it. The some() version is easier to read in my opinion. That said, I know a lot of JavaScript devs don't know or use this operator. I agree with@sebmck's point about ! inversion though. It's a C-ism that doesn't really help readability -
That said, at least the counterexample uses for/of which is much better than for/in
- 3 more replies
New conversation -
Loading seems to be taking a while.
Twitter may be over capacity or experiencing a momentary hiccup. Try again or visit Twitter Status for more information.
he/him 