How To Modify Deep Vuex Data With V-model
I'm trying to modify a vuex store, but using v-model on a key deep inside the object. Obviously when modifying data it must be done using mutations. But i'm struggling to figure ou
Solution 1:
You won't be able to use a computed property for this. Don't use v-model
, instead bind to :value
and register your own event listener.
https://jsfiddle.net/jamesbrndwgn/L27pcksn/88/
You may also want to read about normalizing state shape. It will make working with Objects much simpler and avoid deep nesting.
Post a Comment for "How To Modify Deep Vuex Data With V-model"