Run details:
Mozilla/5.0 (iPhone; CPU iPhone OS 15_5 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/15.5 Mobile/15E148 Safari/604.1
Mobile Safari 15
iOS 15.5
Mobile
one year ago
Test name Executions per second
lodash.each 808.7 Ops/sec
native for-of w/ entries 702.2 Ops/sec
native forEach w/ entries 704.2 Ops/sec
vanilla for-loop w/ Object.keys 579.7 Ops/sec
vanilla for-loop w/ Object.entries 624.8 Ops/sec
vanilla for-loop w/ Object.values (no keys) 646.9 Ops/sec
native forEach w/ Object.values (no keys) 625.0 Ops/sec
native for-in 508.4 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • lodash.each

  • native for-of w/ entries

  • native forEach w/ entries

  • vanilla for-loop w/ Object.keys

  • vanilla for-loop w/ Object.entries

  • vanilla for-loop w/ Object.values (no keys)

  • native forEach w/ Object.values (no keys)

  • native for-in