Toggle navigation
MeasureThat
.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
Run results for:
Arrays: spread operator vs push
Go to the benchmark
Embed
Embed Benchmark Result
Run details:
User agent:
Mozilla/5.0 (X11; Linux x86_64; rv:137.0) Gecko/20100101 Firefox/137.0
Browser:
Firefox 137
Operating system:
Linux
Device Platform:
Desktop
Date tested:
one year ago
push function
148.3M/s
spread operator
34.5M/s
View exact numbers
Test name
Executions per second
✓
push function
148,305,088 Ops/sec
spread operator
34,487,384 Ops/sec
Tests:
spread operator
var arr = [1, 2, 3]; var out = [...arr, 4];
push function
var arr = [1, 2, 3]; arr.push(4);