0% found this document useful (0 votes)
5 views14 pages

Object Methods

Javascript object methods
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views14 pages

Object Methods

Javascript object methods
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 14

JavaScript Object

Methods
[email protected]

soumyabalamaala soumyabalamaala
1. Object.keys()
Definition:
Returns an array of a given object’s property
names.

[email protected]

soumyabalamaala soumyabalamaala
2. Object.values()
Definition:
Returns an array of a given object’s property
values.

[email protected]

soumyabalamaala soumyabalamaala
3. Object.entries()
Definition:
Returns an array of a given object’s own
enumerable string-keyed property [key, value]
pairs.

[email protected]

soumyabalamaala soumyabalamaala
4. Object.assign()

Definition:
Copies the values of all enumerable own
properties from one or more source objects to a
target object. It returns the target object.

[email protected]

soumyabalamaala soumyabalamaala
5. Object.freeze()
Definition:
Freezes an object, preventing new properties
from being added, existing properties from
being removed, or existing properties from
being modified.

[email protected]

soumyabalamaala soumyabalamaala
6. Object.seal()
Definition:
Seals an object, preventing new properties from
being added and marking all existing properties
as non-configurable.

[email protected]

soumyabalamaala soumyabalamaala
7. Object.getPrototypeOf()

Definition:
Returns the prototype of the specified object.

[email protected]

soumyabalamaala soumyabalamaala
8. Object.setPrototypeOf()
Definition:
Sets the prototype of a specified object to
another object or null.

[email protected]

soumyabalamaala soumyabalamaala
9. Object.create()
Definition:
Creates a new object with the specified
prototype object and properties.

[email protected]

soumyabalamaala soumyabalamaala
10. Object.create()
Definition:
Creates a new object with the specified
prototype object and properties.

[email protected]

soumyabalamaala soumyabalamaala
11. Object.defineProperty()
Definition:
Adds a property to an object, or modifies an
existing property, and returns the object.

[email protected]

soumyabalamaala soumyabalamaala
12. Object.defineProperties()
Definition:
Defines new properties or modifies existing
properties on an object, and returns the object.

[email protected]

soumyabalamaala soumyabalamaala
Follow for more such
content on JavaScript
[email protected]

soumyabalamaala soumyabalamaala

You might also like