Hello,
I have a Geojson file. I would like to create a new key-value pair in properties.
Current properties of an object looks like it.
{
"properties": {
"name": "Seattle",
"type": "CITY",
"template": "Prohibited",
"id": 1,
"TRANDESCRI": "MAJOR TRANSIT ROUTE",
"SLOPE_PCT": 1,
"PVMTCATEGO": "ART",
"PARKBOULEV": "N",
"SHAPE_Leng": 666.1146823345148,
"_related_candidates": "0"
}
And I would like to create new key in properties which is called 'description' and it should have the other key-value pairs in it. So it should look like this
{ "properties": { "name": "Seattle", "type": "CITY", "template": "Prohibited", "id": 1, "TRANDESCRI": "MAJOR TRANSIT ROUTE", "SLOPE_PCT": 1, "PVMTCATEGO": "ART", "PARKBOULEV": "N", "SHAPE_Leng": 666.1146823345148, "_related_candidates": "0", "description": { "name": "Seattle", "type": "CITY", "template": "Prohibited", "id": 1 } }}
or (description is a list here)
{ "properties": { "name": "Seattle", "type": "CITY", "template": "Prohibited", "id": 1, "TRANDESCRI": "MAJOR TRANSIT ROUTE", "SLOPE_PCT": 1, "PVMTCATEGO": "ART", "PARKBOULEV": "N", "SHAPE_Leng": 666.1146823345148, "_related_candidates": "0", "description": m{ "name": "Seattle", "type": "CITY", "template": "Prohibited", "id": 1 }] }}
Thanks in advance.