object.keys + lookup + for loop vs. object.entries.forEach (version: 0)
Compares the speed of getting an array of keys and looking up the object values with those keys (in a loop) with simply calling `.forEach` on `object.entries()`
Comparing performance of: Object.entries.forEach vs Object.keys + lookup + for loop
Memory measurements supported only in Chrome.
For precise memory measurements Chrome must be launched with --enable-precise-memory-info flag.
More information: Monitoring JavaScript Memory
Test case name
Result
Object.entries.forEach
Object.keys + lookup + for loop
Fastest:N/A
Slowest:N/A
Latest run results:
Run details: (Test run date:
one year ago)
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/113.0.0.0 Safari/537.36