Answer the question
In order to leave comments, you need to log in
How to add a snapshot of the current state in Vuex?
In store vuex:
const state = {
filter_list: [], - тут хочу хранить слепки
filter: { - текущие состояние 2х инпутов, связано через v-model
input1:'',
input2:''
}
}
FILTER_SAVE (state) {
state.filter_list.push({filter: state.filter})
}
Answer the question
In order to leave comments, you need to log in
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question