-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Uncaught TypeError: Cannot read property 'SVGElement' of undefined #162
Comments
That's odd. Strict mode is intended and implied in Babel modules, but Webpack should be handling global injection properly. I don't see this issue on any of the demos. Perhaps it has something to do with your environment? |
Exactly same issue for me. I've got no idea how to fix it. |
You could help by giving me reproduction steps. |
Thanks for your quick response. In console: In code:
Btw component is dragging properly. |
Might be that I found a workaround. Observed the same error when the code of Looks like some Webpack + Babel issue. |
In v2.1.1 I'm getting this error when trying to use
Draggable
:react-draggable.js:267 Uncaught TypeError: Cannot read property 'SVGElement' of undefined
It looks like the problem has to do with
global
beingundefined
due to(function() { return this; })()
returningnull
rather than the global object in strict mode. I'm not really sure why it's being executed in strict mode though.The text was updated successfully, but these errors were encountered: