I am trying to convert the "count" key from each object within the test array into a new array so I end up with something like
newCount =[0,0,0,0]
const test = [
{
id: 0,
count: 0,
image: "",
text: 'Some text about finn'
},
{
id: 1,
count: 0,
image: "",
text: 'Some text about daphne'
},
{
id: 2,
count: 0,
image: "",
text: 'Some text finn'
},
{
id: 3,
count: 0,
image: "",
text: 'Some text daphne'
}
]