Array.of vs spread operator

Benchmark created on


Test runner

Ready to run.

Testing in
TestOps/sec
Array.of
const array_of = (...args) => Array.of(...args);
array_of(1,2,3,4);
ready
Spread
const array_of = (...args) => [...args];
array_of(1,2,3,4);
ready

Revisions

You can edit these tests or add more tests to this page by appending /edit to the URL.