Echo JS 0.11.0

<~>
gotofritz 2318 days ago. link 2 points
Surely a better way to get the first n items from an array is with a slice?

    arr
      .slice(0, n)
      .map(..or whatever...)

Replies

Swizz 2318 days ago. link 1 point
`map` performance is no longuer a problem ?
sashee 2318 days ago. link 1 point
In like 99% of all the cases, it's not. Only every few months I find a problem that is slow and refactoring it to something other than `map` shows a discernible improvement.

So it's rare.
sashee 2318 days ago. link 1 point
You're right, that would further simplify it.