Run details:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/95.0.4638.69 Safari/537.36
Chrome 95
Windows
Desktop
3 years ago
Test name Executions per second
For ... in length test 13887039.0 Ops/sec
Object.keys length test 5085510.5 Ops/sec
Object.values length test 4290576.0 Ops/sec
Object.entries length test 4107385.5 Ops/sec
For In Reduce test 1770222.4 Ops/sec
Object.keys Reduce test 1442577.2 Ops/sec
Object.values Reduce test 4119548.0 Ops/sec
Object.entries reduce test 3848598.2 Ops/sec
Script Preparation code:
Tests:
  • For ... in length test

  • Object.keys length test

  • Object.values length test

  • Object.entries length test

  • For In Reduce test

  • Object.keys Reduce test

  • Object.values Reduce test

  • Object.entries reduce test