【发布时间】:2019-02-28 15:53:14
【问题描述】:
我正在使用带有服务器端生成选项标签的 b-form-select:
<b-form-select :state="errors.has('type') ? false : null"
v-model="type"
v-validate="'required'"
name="type"
plain>
<option value="note" >Note</option>
<option value="reminder" >Reminder</option>
</b-form-select>
当没有为此字段设置数据时,我想自动选择列表中的第一个选项。
这可能吗?我还没有找到如何从我的 Vue 实例中访问组件的选项。
【问题讨论】:
标签: bootstrap-vue