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
window.html2canvas is undefined if a module loader is used #834
Comments
As a result you get a
error in IE, whenever it tries to use fabric. An AMD workaround: require(["html2canvas", "html2canvas.svg"], function(html2canvas, svg) {
window.html2canvas = {
svg: svg
}; |
And if you're using babel/es6:
|
Tried to do this and I am getting an blank image..any idea of what could be causing this?
when I display that image is blank. |
I had the same issue in MSIE 11.1, but it does not happen in Chrome. A variant on nearwood's workaround stops the error, but SVGs do not render properly:
@niklasvh, why did you close this? Is it thought fixed? I don't see any commits which reference this issue: do you have a link to what fixed this in Chrome, so I can take a look at why it is still broken in MSIE? |
Because html2canvas and html2canvas.svg are bundled as UMD, window.html2canvas will be undefined in applications that use a module loader.
The text was updated successfully, but these errors were encountered: