I'm beginner with Vues.js and i'm asking something about mapMutation method. I want to pass parameters with this method but i don't know how. I want to transform my two methods by using mapMutations :
increment() {
this.$store.commit(M_COUNT_INCREMENT, {
amount: 1,
});
},
decrement() {
this.$store.commit(M_COUNT_DECREMENT, {
amount: 1,
});
},
I want do thing like this but with passing my "amount" parameter :
...mapMutations({
increment: M_COUNT_INCREMENT,
decrement: M_COUNT_DECREMENT,
}),
Any idea ?
Thank's