Run details:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_13_5) AppleWebKit/605.1.15 (KHTML, like Gecko) CriOS/92 Version/11.1.1 Safari/605.1.15
Safari 11
Mac OS X 10.13.5
Desktop
3 years ago
Test name Executions per second
lodash/keyBy 1987373.9 Ops/sec
keyBy with native reduce 2204247.2 Ops/sec
keyBy with forEach 1430562.5 Ops/sec
keyBy with for loop 2372912.5 Ops/sec
HTML Preparation code:
Script Preparation code:
Tests:
  • lodash/keyBy

  • keyBy with native reduce

  • keyBy with forEach

  • keyBy with for loop