小程序获取 图片宽高

<image
binderror="errImg"
bindload="imgload" style="width:{{item.attribute.scaleWidth }};height:{{item.attribute.scaleHeight }}" mode="widthFix" src="{{item.type==1? item.seven:item.url+'-2k'}}"></image>
  //加载成功   
imgload: function (e) { console.log(e) },

//加载失败
errImg
(e) {
      console.log(e)
  
    },
 
 

 

posted @ 2020-07-23 17:19  风一样的猿  阅读(1285)  评论(0)    收藏  举报