I have from a mongoose query result:
{
"store": [
{
"items": [
"A1",
"A2"
]
},
{
"items": [
"A3",
"A4"
]
},
{
"items": [
"B1",
"B2"
]
},
{
"items": [
"B3",
"B4"
]
},
{
"items": [
"C8",
"C9",
"C10"
]
}
]
}
I need this: [“A1″,”A2″,”A3″,”A4″,”B1″,”B2″,”B3″,”B4″,”C8″,”C9”,C10]
Is there any way to do this without using foreach loop, as my array will be so long and it will be time consuming.