【发布时间】:2020-05-06 08:39:19
【问题描述】:
我目前正在尝试使用 Buefy CSS 框架设置我的 Gridsome 应用程序的样式。除了 Carousel 之外,其他一切都运行良好(按钮、卡片等)。特别是 <b-carousel> 标记。
这是代码
<template>
<DefaultLayout>
<template>
<b-carousel :indicator-inside="false">
<b-carousel-item v-for="(item, i) in 6" :key="i">
<span class="image">
<img :src="getImgUrl(i)">
</span>
</b-carousel-item>
<template slot="indicators" slot-scope="props">
<span class="al image">
<img :src="getImgUrl(props.i)" :title="props.i">
</span>
</template>
</b-carousel>
</template>
</DefaultLayout>
</template>
<script>
export default {
methods: {
getImgUrl(value) {
return `https://picsum.photos/id/43${value}/1230/500`
}
}
}
</script>
请帮忙
【问题讨论】:
-
能分享一下控制台截图吗?
-
@Ishu 控制台没有错误。图像没有显示
-
您是否检查过不同的角落,例如,图像链接是否已正确生成并分配给标记?检查容器是否可见。
标签: javascript css vue.js buefy gridsome