m_vue_waterfall
v0.0.7
Published
vue waterfall
Downloads
2
Readme
###使用方式
- 安装
npm install --save m_vue_waterfall
- 使用
import waterfall from 'm_vue_waterfall'
Vue.use(waterfall)
<waterfall :data="lists" :gap="10" :col={2}>
<template v-slot="{item}">
<div class="item">
<div class="tit">{{item.name}}</div>
<div class="con">{{item.con}}</div>
</div>
</template>
</waterfall>
- 属性说明
- data:表示传入的列表数据json格式。
- gap:表示瀑布流两列的间隔宽度,传入number类型
- col: 表示多少列
- template标签表示自定义单个的子项的模板,v-slot来接受单个子项的数据。