Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_14_6) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/87.0.4280.141 Safari/537.36 Edg/87.0.664.75
Chrome 87
Mac OS X 10.14.6
Desktop
3 years ago
Test name Executions per second
Object.entries 3.8 Ops/sec
for..in 3.6 Ops/sec
Object.keys 3.7 Ops/sec
Object.keys no entry 3.9 Ops/sec
for..in no array 3.8 Ops/sec
Object.entries no array 3.9 Ops/sec
Script Preparation code:
Tests:
  • Object.entries

  • for..in

  • Object.keys

  • Object.keys no entry

  • for..in no array

  • Object.entries no array