Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:109.0) Gecko/20100101 Firefox/109.0
Firefox 109
Mac OS X 10.15
Desktop
one year ago
Test name Executions per second
Map - for of kv 1700696.6 Ops/sec
Map - forEach 5116925.0 Ops/sec
Object.entries() - for of kv 1400028.1 Ops/sec
Object.entries() - forEach 191247.3 Ops/sec
Object - for in 5907332.5 Ops/sec
Script Preparation code:
Tests:
  • Map - for of kv

  • Map - forEach

  • Object.entries() - for of kv

  • Object.entries() - forEach

  • Object - for in