9***@qq.com
9***@qq.com
  • 发布:2020-09-03 09:44
  • 更新:2020-10-26 15:45
  • 阅读:1734

【报Bug】uni.createCanvasContext('canvasdrawer', this)语法报错。

分类:uni-app

产品分类: uniapp/小程序/微信

PC开发环境操作系统: Windows

PC开发环境操作系统版本号: 1

HBuilderX类型: 正式

HBuilderX版本号: 2.7.14

第三方开发者工具版本号: 1.03.2008272

基础库版本号: 2.8.0

项目创建方式: HBuilderX

示例代码:

this.ctx = uni.createCanvasContext('canvasdrawer', this)

操作步骤:

使用这段语法就会报错

预期结果:

不报错,正常获取

实际结果:

报错

bug描述:

canvas生成图片,this.ctx = uni.createCanvasContext('canvasdrawer', this)语法报错。

2020-09-03 09:44 负责人:无 分享
已邀请:
9***@qq.com

9***@qq.com (作者)

希望哪位大佬能够帮帮忙解解惑

9***@qq.com

9***@qq.com (作者)

顶一下

9***@qq.com

9***@qq.com (作者)

顶一下

9***@qq.com

9***@qq.com (作者)

顶顶顶顶顶

9***@qq.com

9***@qq.com (作者)

顶一下顶一下

s***@yeah.net

s***@yeah.net

顶一下顶一下

s***@yeah.net

s***@yeah.net

同样的问题,以前一切正常,这两天突然就报错

c***@163.com

c***@163.com

在最新版本的微信小程序开发工具里面使用,是会有报错的

叫啥好呢

叫啥好呢

https://ask.dcloud.net.cn/question/106399 是这种保错吗

1***@qq.com

1***@qq.com - 是心跳吗

我也会报uni.createCanvasContext('abowcanvas',_this)自定义组件会报Property or method "toJSON" is not defined on the instance but referenced during render. Make sure that this property is reactive, either in the data option, or for class-based components, by initializing the property.

1***@qq.com

1***@qq.com - 是心跳吗

我也会报uni.createCanvasContext('abowcanvas',_this)自定义组件会报Property or method "toJSON" is not defined on the instance but referenced during render. Make sure that this property is reactive, either in the data option, or for class-based components, by initializing the property.

  • 即时通讯开发

    解决了吗 ,我也遇到这个问题

    2020-09-09 18:07

  • 1***@qq.com

    回复 即时通讯开发:你发布到网上就可以不要管编辑器,要么重新安装编辑器uniapp和微信小程序的编辑器

    2020-09-14 17:21

  • 即时通讯开发

    回复 1***@qq.com: 对的 我再手机上测试没有问题,发布以后也没有问题,就是在编辑器上有问题

    2020-09-19 10:03

即时通讯开发

即时通讯开发

同样遇到这个错误

DDante

DDante

同样也是该问题最近测试发现了,估计就是跟开发者编辑器最新版本有关系

DCloud_UNI_GSQ

DCloud_UNI_GSQ

和 HBuilderX 版本无关,新版的微信开发工具有此 Bug,可以先下载回 1.03.2006090

该问题目前已经被锁定, 无法添加新回复