1.下载插件放到项目 components目录下
2. 引入并注册
import taozhiSkeleton from '@/components/taozhiSkeleton/taozhiSkeleton.vue' // 骨架屏
export default {
components: {
taozhiSkeleton
},
}
3. 使用
<taozhi-skeleton type="listTransverse" :number="3"></taozhi-skeleton>
4. 参数说明
参数名 | 类型 | 说明 |
---|---|---|
type | String | 骨架屏类型 |
animation | Boolean | 是否启动动画 |
number | Number | 列表item数量 |
type参数
字段 | 说明 |
---|---|
listTransverse | 横向列表 |
listVertical | 纵向列表 |
listAudio | 音频列表 |
listCourse | 图文、课程列表 |
listGrid | 九宫格列表 |
listPartner | 用户、商户列表 |
listBook | 书籍列表 |