Fish Touching🐟🎣

JavaScript Object

Apr 3, 2023

JavaScript Array
JavaScript Date Object
JavaScript Map and Set
JavaScript WeakMap
Src

JavaScript objects can be thought of as simple collections of name-value pairs. As such, they are similar to:

There are two basic ways to create an empty object:

const obj = new Object();
const obj = {};

Object.keys,values,entries

对于普通对象,下列这些方法是可用的:

# Objects Vs Map


# Objects Prototype

Object prototypes - Learn web development | MDN
Every object in JavaScript has a built-in property, which is called its prototype. The prototype is itself an object, so the prototype will have its own prototype, making what’s called a prototype chain. The chain ends when we reach a prototype that has null for its own prototype.