Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/105.0.0.0 Safari/537.36
Chrome 105
Mac OS X 10.15.7
Desktop
2 years ago
Test name Executions per second
lodash.each 778.2 Ops/sec
lodash.map 754.3 Ops/sec
Object.entries.map 455.3 Ops/sec
vanilla for-loop w/ Object.entries 629.5 Ops/sec
lodash.forEach 792.0 Ops/sec
Object.values for 693.5 Ops/sec
Object.keys for 1285.7 Ops/sec
Object.keys for in 1121.1 Ops/sec
Object.values for of 693.2 Ops/sec
Object.keys for of 797.6 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • lodash.each

  • lodash.map

  • Object.entries.map

  • vanilla for-loop w/ Object.entries

  • lodash.forEach

  • Object.values for

  • Object.keys for

  • Object.keys for in

  • Object.values for of

  • Object.keys for of