Test case name | Result |
---|---|
Object.fromEntries with Array.map | |
new Map with Array.map | |
Reduce (reusing object) | |
Reduce (creating temporary objects) |
Test name | Executions per second |
---|---|
Object.fromEntries with Array.map | 2345.3 Ops/sec |
new Map with Array.map | 1569.9 Ops/sec |
Reduce (reusing object) | 10416.8 Ops/sec |
Reduce (creating temporary objects) | 100.0 Ops/sec |