Test name | Executions per second |
---|---|
Native slice | 160052.7 Ops/sec |
lodash chunk | 1588.6 Ops/sec |
<script src='https://cdnjs.cloudflare.com/ajax/libs/lodash.js/4.17.5/lodash.min.js'></script>
var test = Array.from({
length: 100000
}, () => Math.random())
test.slice(0,5000)
_.chunk(test,5000)