JavaScript: Array Object

By Xah Lee. Date: . Last updated: .

Array is the value of the property key "Array" of the global object.

console.log( window["Array"] === Array ); // true

Array is a function.

〔►see JavaScript: Data Types

// type of Array
console.log ( typeof Array === "function" ); // true
console.log ( === "[object Function]" ) // true

The parent of Array is Function.prototype. 〔►see JavaScript: Prototype and Inheritance

// parent of Array
console.log ( Object.getPrototypeOf ( Array ) === Function.prototype ); // true

The purpose of Array is:

  1. To create array objects.
  2. Used as a namespace to hold general purpose methods for working with array objects.
  3. Holds the property key "prototype". The value of Array.prototype is the parent object of all array objects.

Array Constructor

JavaScript: Array Constructor



JavaScript: Array.prototype


Array.isArray ( value )

Returns true if value is a array object. (not a array-like object.) Else, false.

〔►see JavaScript: Array-Like Object

ECMAScript 2015 §Indexed Collections#sec-array.isarray


〔►see JavaScript: Array.from


〔►see JavaScript: Array.of


ECMAScript® 2016 Language Specification#sec-array-objects

Array Topic

  1. JavaScript: Array Basics
  2. JavaScript: Understand JS Array
  3. JavaScript: Create Array
  4. JavaScript: Sparse Array
  5. JavaScript: Array-Like Object
  6. JavaScript: Array How-To

  1. JavaScript: Array Object
  2. JavaScript: Array.prototype
Like what you read? Buy JavaScript in Depth
or, buy a new keyboard, see Keyboard Reviews.