If there is a Javascript object with multiple levels, as in:
myObject = {
a: 12,
obj11: {
obj111: \'John\',
b
To increment the discussion, if you're using lodash you can also use the function _.get to get the value like this:
_.get(myObject, ['obj111', 'obj1111'])
//returns 'John'
If you object has properties with array values you can also get by indexes
var obj = {
a: 1,
b:[{
d:4,
c:8
}]
_.get(obj, ['b','0','d'])
//returns 4
Source: https://lodash.com/docs/4.17.4#get