I am in need of generating a JSON structure that follows this specific format:
{"content": {
"properties": {
"area_id": "20",
"origin": "3",
"axis": "1",
"x_start": "00",
"x_end": "99",
"y_start": "00",
"y_end": "99",
"lgpla": "20-01050105-0102",
}
},
"content": {
"properties": {
"area_id": "24",
"origin": "5",
"axis": "1",
"x_start": "00",
"x_end": "99",
"y_start": "00",
"y_end": "99",
"lgpla": "20-01050105-0102",
}
}
}
The values within this data should be populated dynamically from an array. I have attempted to initialize a variable called postdata and loop through the data, but when checking the console, all I see is [object object]. I am seeking suggestions on how to move forward with this process.
Thank you