Answer the question
In order to leave comments, you need to log in
How to setup v-switch filter for json?
1. there is a switch <v-switch v-model="filtered">
2. there is a json array with objects that contain the following structure:
list: [
{
...,
...,
stateId: 1
...,
},
{
...,
...,
stateId: 0
...,
},
{
...,
...,
stateId: 0
...,
},
{
...,
...,
stateId: 1
...,
}
]
,
computed: {
stateId() {
return this.list.stateId;
}
},
methods: {
filtered() {
return //- как настроить фильтр?
}
}
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