JSON object as below. Need to find the value based on user input. The input will look like "data.location.type"
, or "data.location.items[1].address.street"
. Can it be done in JQuery?
{
"data": {
"location": {
"type": "List",
"count": 1,
"items": [
{
"id": 1,
"type": "S",
"address": {
"street": "123 Main St",
"city": "New York",
"state": "NY"
}
},
{
"id": 2,
"type": "S",
"address": {
"street": "1323 South St",
"city": "New York",
"state": "NY"
}
}
]
}
}
}