-
Notifications
You must be signed in to change notification settings - Fork 88
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
After creating a MarkerClusterer unable to register 'mouseover' event on the clusterer object #715
Comments
If you would like to upvote the priority of this issue, please comment below or react on the original post above with 👍 so we can see what is popular when we triage.@Ubaid-ur-Rehman Thank you for opening this issue. 🙏
This is an automated message, feel free to ignore. |
Any update on this issue? |
@wangela Still waiting for response. |
The What you can do is provide your own renderer implementation to the import {DefaultRenderer} from '@googlemaps/js-markerclusterer';
class RendererWithEvents extends DefaultRenderer {
render(cluster: Cluster, stats: ClusterStats, map: google.maps.Map): Marker {
const marker = super.render(cluster, stats, map);
// handle events for the newly created marker
marker.addListener('mouseover', () => {
console.log('cluster hovered!', cluster)
});
return marker;
}
}
const clusterer = new MarkerClusterer({
map,
markers,
renderer: new RendererWithEvents()
});
|
mhmmm this method doesn't work for me, did it work for you? @Ubaid-ur-Rehman do you have a workaround to get the mouse over functionality? |
I want to show some data in the info window after creating the clusterer but the event is not being registered.
The text was updated successfully, but these errors were encountered: