Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
Run results for:
ES6 Map vs Hash Table vs Keys
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/132.0.0.0 Safari/537.36 Edg/132.0.0.0
Browser:
Chrome 132
Operating system:
Windows
Device Platform:
Desktop
Date tested:
one year ago
Test name
Executions per second
Array
38354324.0 Ops/sec
Hash Table
63652484.0 Ops/sec
ES6 Map
7965822.0 Ops/sec
Tests:
Array
const myObj = {a:1,b:2,c:3} const myArr = Object.keys(myObj) myArr.includes("c")
Hash Table
const myObj = {a:1,b:2,c:3} myObj.hasOwnProperty("c")
ES6 Map
const myObj = {a:1,b:2,c:3} const myMap = new Map(Object.entries(myObj)) myMap.has("c")