Here is some code for a Vuex mutation:
export const CREATE_PANORAMAS = (state, panoramas) => {
console.log('building.panoramas:', state.building.panoramas)
console.log('panoramas:', panoramas)
state.building.panoramas.concat(panoramas)
console.log('result:', state.building.panoramas)
}
After running the code, we see the following logs:
[] // building.panoramas
[{ name: "", objectId: "5849133aac502e006c581b58" }] // panoramas
[] // result
The issue here is that the two arrays are not concatenating. Why could this be happening?