mirror of
https://github.com/tusen-ai/naive-ui.git
synced 2025-01-24 12:45:18 +08:00
520 B
520 B
Group
<n-auto-complete :options="options" v-model:value="value" placeholder="Email" />
export default {
computed: {
options () {
return [
['Google', '@gmail.com'],
['Netease', '@163.com'],
['Tencent', '@qq.com']
].map((emailInfo) => {
return {
type: 'group',
name: emailInfo[0],
children: [this.value.split('@')[0] + emailInfo[1]]
}
})
}
},
data () {
return {
value: ''
}
}
}