0👍
See this fiddle for a working example. v-model
doesn’t need the :
in front.
new Vue({
el: '#app',
data: {
message: 'Hello Vue.js!',
items: [{
key: "test one"
},
{
key: "test two"
},
{
key: "test three"
}]
}
})
and the dom:
<script src="https://unpkg.com/vue"></script>
<div id="app">
<p>{{ message }}</p>
<div v-for="(item, index) in items" :key="index">
<input v-model="item.key" />
</div>
</div>
Docs link: Vue form bindings
- [Vuejs]-How to open a vue component in new tab without page load by vue router?
- [Vuejs]-Vue: How to pass custom props and router props?
Source:stackexchange.com