Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Canvas在3.0.7版本后,无法正常绘制图片 #7437

Closed
Kybs0 opened this issue Aug 25, 2020 · 0 comments
Closed

Canvas在3.0.7版本后,无法正常绘制图片 #7437

Kybs0 opened this issue Aug 25, 2020 · 0 comments
Labels
duplicate This issue or pull request already exists F-react Framework - React T-weapp Target - 编译到微信小程序 V-3 Version - 3.x

Comments

@Kybs0
Copy link

Kybs0 commented Aug 25, 2020

相关平台

微信小程序

复现仓库

https://github.com/Neilai/Taro-bug
小程序基础库: 2.12.0
使用框架: React

复现步骤

通过WeCropper加载裁剪图片,
使用Canvas来显示。
在3.0.6版本时,显示正常。但是3.0.7版本之后,就黑屏无法正常显示了。
已经有个issue:#7314

这个问题,根本原因,还是Canvas设置默认type的问题。所以能否删除默认type?可见即所得,代码清真一点~

期望结果

Canvas不要默认type,解决Canvas不能绘图的问题

实际结果

当前Canvas设置了默认type=‘2d’,不支持绘图

环境信息

Taro CLI 3.0.7 environment info:
    System:
      OS: macOS 10.14.6
      Shell: 5.3 - /bin/zsh
    Binaries:
      Node: 12.18.2 - ~/.nvm/versions/node/v12.18.2/bin/node
      Yarn: 1.22.4 - /usr/local/bin/yarn
      npm: 6.14.5 - ~/.nvm/versions/node/v12.18.2/bin/npm
    npmPackages:
      @tarojs/components: 3.0.7 => 3.0.7
      @tarojs/mini-runner: 3.0.7 => 3.0.7
      @tarojs/react: 3.0.7 => 3.0.7
      @tarojs/runtime: 3.0.7 => 3.0.7
      @tarojs/taro: 3.0.7 => 3.0.7
      @tarojs/webpack-runner: 3.0.7 => 3.0.7
      babel-preset-taro: 3.0.7 => 3.0.7
      eslint-config-taro: 3.0.7 => 3.0.7
      react: ^16.10.0 => 16.13.1
@taro-bot2 taro-bot2 bot added F-react Framework - React T-weapp Target - 编译到微信小程序 V-3 Version - 3.x labels Aug 25, 2020
@Chen-jj Chen-jj added the duplicate This issue or pull request already exists label Aug 26, 2020
@Chen-jj Chen-jj closed this as completed Aug 26, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
duplicate This issue or pull request already exists F-react Framework - React T-weapp Target - 编译到微信小程序 V-3 Version - 3.x
Projects
None yet
Development

No branches or pull requests

2 participants