Toggle navigation
MeasureThat.net
Create a benchmark
Tools
Feedback
FAQ
Register
Log In
Run results for:
reduce concat vs apply concat
Array flat es5 syntax (reduce concat vs apply concat)
Go to the benchmark
Embed
Embed Benchmark Result
Run details:
User agent:
Mozilla/5.0 (Linux; Android 10; K) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/140.0.0.0 Mobile Safari/537.36
Browser:
Chrome Mobile 140
Operating system:
Android
Device Platform:
Mobile
Date tested:
7 months ago
Test name
Executions per second
reduce concat
535041.2 Ops/sec
concat.apply
4116158.0 Ops/sec
Script Preparation code:
var params = [[ 1, 2 ], [ "hello", true, 7 ], {Code: "3", Message: "Какая-то ошибка"},{Code: "2", Message: "Какая-то ошибка"}, [{Code: "1212121212", Message: "то ошибкато ошиб"}]];
Tests:
reduce concat
var other = params.reduce(function(previousValue, currentValue) { return previousValue.concat(currentValue) }, []);
concat.apply
var other = params.concat.apply([], this);