HTML Preparation code:
AخA
 
1
<script type="text/javascript" src="https://cdnjs.cloudflare.com/ajax/libs/lodash.js/4.17.11/lodash.core.js"></script>
Script Preparation code:
 
var users = [
  { 'user': 'joey',  'age': 32 },
  { 'user': 'ross',    'age': 41 },
  { 'user': 'chandler', 'age': 39 }
]
Tests:
  • array find

     
    users.find(x => x === { 'user': 'joey', age: 32 });
  • lodash find

     
    _.find(users, { 'user': 'joey', age: 32 });
Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results

Experimental features:

  • Test case name Result
    array find
    lodash find

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 2 years ago)
Mozilla/5.0 (iPhone; CPU iPhone OS 16_3 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) CriOS/111.0.5563.72 Mobile/15E148 Safari/604.1
Chrome Mobile iOS 111 on iOS 16.3
View result in a separate tab
Test name Executions per second
array find 14105181.0 Ops/sec
lodash find 4904574.0 Ops/sec