<el-carousel :interval="3000" arrow="always" height="570px">
<el-carousel-item v-for="item in imgsList" :key="item.id">
<!--<img :src="item.imgUrl">-->
<div class="imgDiv" :style="{backgroundImage:'url('+item.imgUrl+')'}"></div>
</el-carousel-item>
</el-carousel>
Vue里面的div套用背景图片
最新推荐文章于 2024-03-07 16:10:56 发布