Looking to store values from an array of objects into radio inputs in Vue.js? Here's what I have:
const plans = [{type:'2'},{type:'3'},{type:'1'}]
I attempted the following approach:
<input type="radio" v-model="pick" :value="plans[0]" />
<input type="radio" v-model="pick" :value="plans[1]" />
<input type="radio" v-model="pick" :value="plans[2]" />
Unfortunately, this resulted in the error message:
Invalid prop: type check failed for prop "value". Expected String, Number, got Object
Do you have any suggestions on how to overcome this issue? Thanks!