Can someone help me with looping an AJAX response to create an array in this format?
"2023-03-30": {"number": '', "url": ""},
"2023-03-30": {"number": '', "url": ""}
The loop I'm using is as follows:
var columns = {};
for (var i=0; i < parsed_data.tasks.length; i++) {
var mydate = parsed_data.tasks[i].date;
columns.push(mydate);
}
console.log(columns);
Unfortunately, this code is not yielding the expected output. Any suggestions on how to make it work?