Set default value

Benchmark created on


Test runner

Ready to run.

Testing in
TestOps/sec
param = param || {}
function test1(params) {
    params = params || {};
}

test1(Math.round(Math.random()));
ready
params || (params = {})
function test2(params) {
    params || (params = {});
}

test2(Math.round(Math.random()));
ready

Revisions

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