swiper 本地可以播放图片,但是扫二维码预览的时候,没有了。
发布于 5 年前 作者 yanyong 19218 次浏览 来自 问答

这个是index.wxml

<swiper indicator-dots="{{true}}"

autoplay="{{true}}" interval="{{3000}}" duration="{{1000}}">

<swiper-item>

<image src="{{’…/…/images/shirts/厚毛线长裙.png’}}" class=“slide-image” width=“355” height=“150”/>

</swiper-item>

<swiper-item>

<image src="{{’…/…/images/shirts/打底毛衣.png’}}" class=“slide-image” width=“355” height=“150”/>

</swiper-item>

<swiper-item>

<image src="{{’…/…/images/shirts/打底衫粉色.png’}}" class=“slide-image” width=“355” height=“150”/>

</swiper-item>

<swiper-item>

<image src="{{’…/…/images/shirts/秋冬新款针织衫.png’}}" class=“slide-image” width=“355” height=“150”/>

</swiper-item>

</swiper>

这里是app.json配置:

{

“pages”:[

“pages/index/index”,

“pages/user/user”

],

“window”:{

“backgroundTextStyle”:“light”,

“navigationBarBackgroundColor”: “#fff”,

“navigationBarTitleText”: “首页”,

“navigationBarTextStyle”:“black”

},

“tabBar”: {

“color”: “#6e6d6b”,

“selectedColor”: “#f9f027”,

“borderStyle”: “red”,

“backgroundColor”: “#292929”,

“list”: [

{

“pagePath”: “pages/index/index”,

“iconPath”: “images/home-grey.png”,

“selectedIconPath”: “images/home-yellow.png”,

“text”: “首页”

},

{

“pagePath”: “pages/user/user”,

“iconPath”: “images/footer-icon-04.png”,

“selectedIconPath”: “images/footer-icon-04-active.png”,

“text”: “用户中心”

}

]

},

“debug”: false

}

2 回复

大家可以随便找几个图片试试

我说的预览,是指

这个预览

回到顶部