Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
destructuring assignmen
(version: 1)
Comparing performance of:
direct vs destructuring
Created:
9 days ago
by:
Registered User
Jump to the latest result
HTML Preparation code:
<!--your preparation HTML code goes here-->
Script Preparation code:
async function getStuff() { return {foo1: 1, bar1: 2,foo2: 1, bar2: 2}; }
Tests:
direct
const data = getStuff(); const s = data.foo1 + data.bar2;
destructuring
const {foo1, bar2} = getStuff(); const s = foo1 + bar2;
Rendered benchmark preparation results:
Suite status:
<idle, ready to run>
Run tests (2)
Previous results
Fork
Test case name
Result
direct
destructuring
Fastest:
N/A
Slowest:
N/A
Latest run results:
Run details:
(Test run date:
9 days ago
)
User agent:
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/147.0.0.0 Safari/537.36
Browser/OS:
Chrome 147 on Linux
View result in a separate tab
Embed
Embed Benchmark Result
Test name
Executions per second
direct
55874712.0 Ops/sec
destructuring
59972600.0 Ops/sec
Related benchmarks:
dot vs destructure syntax
fn vs async 2
Assigning new variable
JS Variable Performance (const vs let vs var)
Array splice vs. Set delete
Test direct and destructuring performances
Object vs Map MYTEST2137
Reassignment of Var vs Const vs Let
Complex assign vs destructure
Comments
Confirm delete:
Do you really want to delete benchmark?