I want to fetch the key of key from this object keys can be anything from time to time so i can not use specific key here is the data
{
"test": {
"4": [
{
some data
}
]
},
"case": {
"2": [
{
some data
},
{
some data
}
]
}
}
I have tried this to fetch it is fine but I want fetch only 2nd key, in example i just want to get key not complete object and the thing is i can not specifically mention the data like test or case it can be anything its dynamic.
let vv = _.get(obj,'test')
console.log(vv)
{
"4": [
{
some data
}
]
}