Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
Run results for:
Object Property Access Notation: Destructuring vs. Dot. vs. Bracket with multiple accessing
Go to the benchmark
Embed
Embed Benchmark Result
Run details:
User agent:
Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/126.0.0.0 Safari/537.36 Edg/126.0.0.0
Browser:
Chrome 126
Operating system:
Windows
Device Platform:
Desktop
Date tested:
one year ago
Test name
Executions per second
Destructuring Notation
7596377.0 Ops/sec
Dot Notation
7666295.0 Ops/sec
Bracket Notation
8829224.0 Ops/sec
Script Preparation code:
var globalData = { data: { data: { restaurants : [ { name:"name1", adress:"ad1", city:"city1" }, { name:"name2", adress:"ad2", city:"city2" } ] }, }, };
Tests:
Destructuring Notation
var { data : {data : {restaurants}} } = globalData;
Dot Notation
var dot = globalData.data.data.resturants;
Bracket Notation
var bracket = globalData['data']['data']['restaurants']