I need a list in the following Format in Javascript to populate my graph:
var songs =
{
"Mon": 80,
"Tues": 40,
"Wed": 60,
"Thu": 80,
"Fri": 40,
"Sat": 60,
};
I am getting my data from my API which comes back in a list in the format of:
How can I loop through my list and adapt it to the form of the "songs" list?
Outcome:
var outputList = {
"19 Jan 2021": 2,
"20 Jan 2021" : 5
....
}