We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
No description provided.
The text was updated successfully, but these errors were encountered:
你好,我在看http://fex.baidu.com/blog/2015/11/convert-svg-to-png-at-frontend/ 这篇文章的时候发现canvas 调用toDataUrl 报污染的画布无法导出错误,请问如何解决呢?图片资源响应头设置了cors也不行
Sorry, something went wrong.
@baby2011 将 img 的 crossOrigin 设置为 anonymous
img
crossOrigin
anonymous
const img = new Image(); img.crossOrigin = 'anonymous'; img.onload = () => { // draw img }; img.src = 'http://example.com/image';
https://developer.mozilla.org/zh-CN/docs/Web/HTML/CORS_enabled_image
No branches or pull requests
No description provided.
The text was updated successfully, but these errors were encountered: