Skip to content


Array.isArray() function determines whether the value passed to this function is an array or not. This function returns true if the argument passed is array else it returns false.


obj : Required. The object to be tested.


        Array.isArray() // false
        Array.isArray([]); // true
        Array.isArray('List'); // true
        Array.isArray(new Array()); // true
        Array.isArray(null); // false
        Array.isArray(true); //false
        Array.isArray([1]); // true
        Array.isArray({}); // false
        Array.isArray(undefined); // false
        Array.isArray(25); // false


Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.

%d bloggers like this: