Script Preparation code:
Tests:
  • unique by map, extract with deconstruct

  • obj UniqueBy, extract with for...in loop

  • obj UniqueBy, extract with Object.values()

  • unique by map, extract with ArrayFrom

  • bad uniqueBy, reducer has an array deconstructor

Rendered benchmark preparation results:

Suite status: <idle, ready to run>

Previous results
  • Test case name Result
    unique by map, extract with deconstruct
    obj UniqueBy, extract with for...in loop
    obj UniqueBy, extract with Object.values()
    unique by map, extract with ArrayFrom
    bad uniqueBy, reducer has an array deconstructor

    Fastest: N/A

    Slowest: N/A

Latest run results:
Run details: (Test run date: 3 years ago)
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/93.0.4577.82 Safari/537.36
Chrome 93 on Mac OS X 10.15.7
View result in a separate tab
Test name Executions per second
unique by map, extract with deconstruct 110758.2 Ops/sec
obj UniqueBy, extract with for...in loop 12161.0 Ops/sec
obj UniqueBy, extract with Object.values() 12216.4 Ops/sec
unique by map, extract with ArrayFrom 79450.8 Ops/sec
bad uniqueBy, reducer has an array deconstructor 44945.5 Ops/sec


;