I have data of json as sample
[{"Food":"Orange T1","Total":3},
{"Food":"Blue T2","Total":1},
{"Food":"Green T3","Total":1},
{"Food":"White T4","Total":4}]
and i want to convert to array object as
[['Orange T1', 3], ['Blue T2', 1], ['Green T3', 1],['White T4', 4]]
How I do this and I will use console.log() to show data sample.
.map({food, total} => [food, total])should do the trick