I pull some data from an API which returns something like this
[{"id":21},{"id":22},{"id":24}]
I will have to post the data received to a database via a different API, but when I'm sending I want it to be sent like [21,22,24]
For example the variable that receives the data from the API is called valuesToSend
which comes [{"id":21},{"id":22},{"id":24}]
but when posting, it should be [21,22,24]
postToDb(){
alert(this.valuesToSend)
}