JavaScript: Array-Like Object

By Xah Lee. Date: . Last updated: .

What is a array-like object

A object such that is all of the following:

[see Understand JS Array]

Create a Array-Like Object

// create a array-like object
let ar = { 0: "a", 1: "b", length: 2 };

console.log(Array.isArray(ar) === false);

Difference Between Array vs Array-Like Object

Check if a object is true array

Where does array-like object came from

Apply Array Method to Array-Like Object

Convert array-like object to array

Get Property Values of Array-Like Object

JavaScript Array

JavaScript: Array-Like Object

BUY
Ξ£JS
JavaScript in Depth

JavaScript in Depth

Basic Syntax

Value Types

Variable

String

Property

Object and Inheritance

Array

Function

Constructor/Class

Iterable 🌟

Misc