用Vuetify呈现列中的v-for项?



我试图用v-for循环呈现v-switch元素,但无法在两列中呈现它们。有人有什么想法吗?

我的代码是这样的:

<v-row>
<v-col>
<v-switch
v-for="item in dominantBottomSubstrate"
:key="item.id"
v-model="selectedDominantBottomSubstrate"
multiple
:value="item.name"
:label="item.value"
>
</v-switch>
</v-col>
</v-row>

谢谢!

应该可以:

<v-row>
<v-col col="6"
v-for="item in dominantBottomSubstrate"
:key="item.id">
<v-switch
v-model="selectedDominantBottomSubstrate"
multiple
:value="item.name"
:label="item.value"
/>
</v-col>
</v-row>

最新更新