Tuesday, 26 March 2019

Vuex - Update entire object inside array

Inside my mutation I want to update an entire object every 10 seconds:

This is my mutation:

UPDATE_MAILING(state, mailing) {
    let index = _.findIndex(state.mailings, {id: mailing.id});

    state.mailings[index] = mailing
}

The way I'm doing is not working. How to achieve this?



from Vuex - Update entire object inside array

No comments:

Post a Comment