-
Notifications
You must be signed in to change notification settings - Fork 180
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
moveend
event handler is invoked after result
is triggered
#131
Comments
moveend
handler is invoked after result
is triggeredmoveend
event handler is invoked after result
is triggered
@Erutan409 I suspect this is because of #99, which causes the result event to be fired twice. As part of that the map tries to animate to the location twice (the first one being interrupted by the second). Interrupting a camera animation with another camera animation in GL JS causes the moveend event to fire, hence you're getting the issue you describe. Unfortunately #99 is not easy to fix for both modern browsers and IE11, so it remains a bug. If you don't need to support IE11 then you can try #99 (comment) and see if that resolves the issue? |
I'll check my code Monday, but I think I solved it with a closure and a brief timeout. It was weird, but necessary. |
This was addressed in #229 and will be fixed when version 4 is released. |
* version4: fixes double moveend event #131
My
moveend
handler is being triggered before the map even starts to move to the location I select from the search results.mapboxgl: v0.41.0
geocoder: v2.1.1
The text was updated successfully, but these errors were encountered: