leaflet-realtime
leaflet-realtime copied to clipboard
Earthquakes example: why markers re-appear on map, when I deselect a overlay layer?
A question about the earthquakes example.
I just started with leaflet and leaflet-realtime, and my JS knowhow is also not so deep (more Java). Great work! Thanks.
When I use the layer control area in the UI and turn off (both)
- Earthquakes 2.5+ and
- All Earthquakes layers, it will re-appear in the next polling interval. My understanding would be: it works like a UI filter. So I (as a user) decide, what to see or not. When I turn off, it is off for the next N intervals until I turn on again.
Finally I'm looking for such a solution. My prototyp is getting a geoJSON structure by a REST call. The "features" (Points) are logically "green/normal", some are "red/critical". So I want to let the user have filter with the overlay layers and select "red" and/or "green". So, if not interested in "green" markers, the user can turn off.
I digging in the internet a long time, but can't find a working solution.
Any hint, especially making earthquakes example having such behavior. So I can select overlay 1 and/or 2.
Thanks in advance. Uwe / Germany
Hi, did you find any solution? Thanks