I am getting this object as response object
{
"data": [
{
"id": "203",
"bench": "abc"
},
{
"id": "205",
"bench": "def"
}
],
"responseCode": 200,
"isSuccess": "true"
}
now I want to add this object on top of the response object
{
"id": "0",
"bench": "Select bench"
}
so the final object should look like this
{
"data": [
{
"id": "0",
"bench": "Select bench"
},
{
"id": "203",
"bench": "abc"
},
{
"id": "205",
"bench": "def"
}
],
"responseCode": 200,
"isSuccess": "true"
}
is there any way to do it in typescript? I tried 'unshift' but it's not working.