- Notifications
You must be signed in to change notification settings - Fork855
Add guard around mapDom event listener#594
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
Fixes an issue where, even if the end user has a proper google maps APImock, the GoogleMaps component will throw an error when in a testenv. ReactDOM.findDOMNode(this.googleMapDom_) returns `null`.This commit wraps the subsequent addEventListener call in an `if` block,ensuring that an empty DOM doesn't add complications to test suites
itsmichaeldiego commentedMay 31, 2018 • edited
Loading Uh oh!
There was an error while loading.Please reload this page.
edited
Uh oh!
There was an error while loading.Please reload this page.
This is great@bignimbus ! Thanks, someone opened a similar PR but provided not as good description as yours. Merging and it will be present in the next release together with other group of changes as this one is not a blocker. Thanks again@bignimbus |
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
Fixes an issue where, even if the end user has a proper google maps API
mock, the GoogleMaps component will throw an error when in a test
env. ReactDOM.findDOMNode(this.googleMapDom_) returns
null
.This commit wraps the subsequent addEventListener call in an
if
block,ensuring that an empty DOM doesn't add complications to test suites
Thank you for your consideration and your hard work on this great library!