TIL: In JavaScript function.length returns the number of arguments it supports

function test(a, b, c)
{

}

alert(test.length);

In this piece of code if you use .length on a function it returns the number of named arguments that this function accepts.

Comments

Popular posts from this blog

The best mobile development platform for hobbyist programmer

Using Voicemail with Airtel Prepaid Karnataka

And yet more invites for joost