如何使用引导程序在循环中创建两列?

时间:2018-07-30 12:29:03

标签: twitter-bootstrap vue.js

这个想法是在每一行(每一行)都有两列,我该如何在vue循环中进行管理?

我希望有什么事情

enter image description here

HTML:

<div class="row">
  <div v-for='(item,indice) in produtos' :key='indice'>
    <q-card inline class="q-ma-sm col-6">
      <q-card-media>
        <img v-bind:src="item.url">
      </q-card-media>
      <q-card-actions align="around">
        <q-btn flat round icon="fas fa-shopping-cart" @click="cart($event,item)"/>
        <q-btn flat round icon="favorite" @click="favorite($event,item)"/>
        <q-btn flat round icon="share" to="whatsapp://send?text=Hello%20World!" />
      </q-card-actions>
    </q-card>
  </div>
</div>

1 个答案:

答案 0 :(得分:2)

您能尝试一下吗?

<div class="row">
  <div v-for='(item,indice) in produtos' :key='indice' class="col-6">
    <h1>{{ item }}</h1>
  </div>
</div>