2
0
mirror of https://github.com/tenrok/vue-select.git synced 2026-06-19 09:50:33 +03:00

nuxt setup, tailwind

This commit is contained in:
Jeff Sagal
2021-07-28 09:46:15 -07:00
parent 335920b586
commit 3399ecbd9a
86 changed files with 5656 additions and 4359 deletions
+43
View File
@@ -0,0 +1,43 @@
<template>
<table>
<tr>
<th>Name</th>
<th>Country</th>
</tr>
<tr v-for="person in people">
<td>{{ person.name }}</td>
<td>
<v-select
:options="options"
:value="person.country"
@input="country => updateCountry(person, country)"
/>
</td>
</tr>
</table>
</template>
<script>
import countries from '../data/countries.js';
export default {
data: () => ({
people: [{name: 'John', country: ''}, {name: 'Jane', country: ''}],
}),
methods: {
updateCountry (person, country) {
person.country = country;
},
},
computed: {
options: () => countries,
},
};
</script>
<style scoped>
table {
display: table;
width: 100%;
}
</style>