开发环境id:yzwdj appid=wx9f66c7f0543a6f00
问题现象:
1 微信开发者工具.exec 运行正常
2 真机环境运行正常
3 微信开发者工具真机测试异常,始终报错误截图:
其中:createView不在什么环境产生的,我的代码中没有这个属性
代码片段:
let that = this
const query = wx.createSelectorQuery()
query.select('#cut-box')
.fields({
node: true,
size: true
})
.exec((res) => {
const canvas = res[0].node
const ctx = canvas.getContext('2d')
const dpr = wx.getSystemInfoSync().pixelRatio
canvas.width = res[0].width * dpr
canvas.height = res[0].height * dpr
ctx.scale(dpr, dpr);
let img = canvas.createImage(); //创建img对象
img.src = that.data.upload_local_url
微信:13883166466
你好,麻烦提供出现问题的具体机型、微信版本号、系统版本号,以及能复现问题的代码片段(https://developers.weixin.qq.com/miniprogram/dev/devtools/minicode.html)
微信版本号: 7.0.22
系统版本号:安卓10
问题:开发环境运行正常、真机运行正常,但开发环境的真机测试部正常,报下列图片错误,其中createView都不知道来自哪里?
开发环境:yzwdj-yzwdj
appid=wx9f66c7f0543a6f00
微信:13883166466