Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:104.0) Gecko/20100101 Firefox/104.0
Firefox 104
Mac OS X 10.15
Desktop
2 years ago
Test name Executions per second
Map - for of kv 1135911.4 Ops/sec
Map - forEach 3749132.0 Ops/sec
Object.entries() - for of kv 930095.1 Ops/sec
Object.entries() - forEach 143657.9 Ops/sec
Object - for in 4356505.5 Ops/sec
Script Preparation code:
Tests:
  • Map - for of kv

  • Map - forEach

  • Object.entries() - for of kv

  • Object.entries() - forEach

  • Object - for in