Array.prototype.filter vs Lodash without 2
Date tested:
one year ago
User agent:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/104.0.0.0 Safari/537.36
Test name
Executions per second
Array.prototype.filter
987.9 Ops/sec
Lodash without
796.2 Ops/sec
Benchmark definition (click to collapse):
HTML Preparation code:
<script src="lodash.js"></script>
Script Preparation code:
var array = [...Array(100000).keys()];
Tests:
Array.prototype.filter
array.filter(n => n === 999)
Lodash without
_.without(array, 999)
Open this result on MeasureThat.net