Can you reference another part of a JSON object within the same JSON object?
In the code snippet below, there is an object that refers to the "home" object within the "MapParameters" object.
{
"parameters": {
"data": {
"URL": "http://SC.json",
"name": "SC"
},
"MapParameters": {
"center": [home.lat, home.lng],
"zoom": home.zoom,
layers: [streets, layers]
},
"basemap": {
"basemapsText": {
"<span class='pointer'>Streets</span>": "streets",
"<span class='pointer'>Satellite</span>": "aerial"
}
"other": {
"scale": {
"maxWidth": 200,
"metric": true,
"imperial": true
},
"home": {
lat: 37.26,
lng: -93.53,
zoom: 7
}
}
}
Is it possible to reference part of a JSON object in this way, and if so, how should it be done?