I have next object:
const obj = {
size: 2,
length: 34,
status: 0,
}
I need to get keys of objects as string: obj.size -> 'size'
, without using loops.
I have next object:
const obj = {
size: 2,
length: 34,
status: 0,
}
I need to get keys of objects as string: obj.size -> 'size'
, without using loops.
var obj = {
size: 2,
length: 34,
status: 0,
};
console.log(
Object.keys(obj)
);