Object.values()
Description
Object.values()
returns an Array containing an Object’s property
values. Object.values()
does not change the original Object.
Objects with non-scalar values
Any nested Arrays in the original Object are left intact, resulting in a multi-dimensional Array. For example:
Object.values({ a: [1, 2], b: 'foo' })
[
[
1,
2
],
"foo"
]
Similarly, any nested Objects in the original Object are left intact:
Object.values({ a: { x: 1, y: 2 }, b: 'foo' })
[
{
x: 1,
y: 2
},
"foo"
]
Is this article helpful?
Tell Fauna how the article can be improved:
Visit Fauna's forums
or email docs@fauna.com
Thank you for your feedback!