Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
Destructuring function argument
(version: 1)
destructure an object into a function.
Comparing performance of:
normal args vs object args
Created:
one year ago
by:
Guest
Jump to the latest result
Tests:
normal args
function foo(a,b,c){ return a + b + c; } console.log(foo(1,2,3));
object args
function foo({a,b,c}){ return a + b + c; } console.log(foo({a: 1,b: 2,c: 3}));
Rendered benchmark preparation results:
Suite status:
<idle, ready to run>
Run tests (2)
Previous results
Fork
Test case name
Result
normal args
object args
Fastest:
N/A
Slowest:
N/A
Latest run results:
Run details:
(Test run date:
4 months ago
)
User agent:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/142.0.0.0 Safari/537.36
Browser/OS:
Chrome 142 on Mac OS X 10.15.7
View result in a separate tab
Embed
Embed Benchmark Result
Test name
Executions per second
normal args
725032.8 Ops/sec
object args
705150.1 Ops/sec
Related benchmarks:
object vs function
Assignment of value vs Destructuring an object
Assignment of value vs Destructuring an object 2
Assignment of values vs Destructuring an object of multiple values
Assignment of value vs Destructuring an object e
Assignment of value vs Destructuring 3 times an object
Passing as param vs destructuring internally
Value vs Destructuring an object
pass by value or by object to destructure
Comments
Confirm delete:
Do you really want to delete benchmark?