Toggle navigation
MeasureThat
.net
Create a benchmark
Tools
Feedback
Feature Requests
FAQ
Register
Log In
Run results for:
Spread vs Array.from performance
Go to the benchmark
Embed
Embed Benchmark Result
Run details:
User agent:
Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:137.0) Gecko/20100101 Firefox/137.0
Browser:
Firefox 137
Operating system:
Mac OS X 10.15
Device Platform:
Desktop
Date tested:
one year ago
Benchmark engine:
Benchmark.js
Array.from
4.9M/s
Spread
4.0M/s
Array.from (more elements)
6K/s
Spread (more elements)
5K/s
View exact numbers
Test name
Executions per second
✓
Array.from
4,856,234 Ops/sec
Spread
4,017,365 Ops/sec
Array.from (more elements)
6,489 Ops/sec
Spread (more elements)
5,091 Ops/sec
Tests:
Spread
[...new Array(10)].map(() => (Math.trunc(Math.random() * 36)).toString(36)).join('');
Array.from
Array.from({ length: 10 }, () => (Math.trunc(Math.random() * 36)).toString(36)).join('');
Spread (more elements)
[...new Array(10000)].map(() => (Math.trunc(Math.random() * 36)).toString(36)).join('');
Array.from (more elements)
Array.from({ length: 10000 }, () => (Math.trunc(Math.random() * 36)).toString(36)).join('');