You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Geoman drawn elements cannot be controlled using a LayerControl #2182
Describe the bug
Elements that are created using Geoman are not enabled/disabled when clicking the appropriate LayerControl layers.
To Reproduce
import folium
from folium.plugins import GeoMan
m = folium.Map(location=[45.5236, -122.6750], zoom_start=13)
# Create a feature group for drawn items
drawn_items = folium.FeatureGroup(name="Drawn Items")
drawn_items.add_to(m)
# Add Geoman with the feature group
GeoMan(feature_group=drawn_items).add_to(m)
# Add layer control to toggle visibility of drawn items
folium.LayerControl().add_to(m)
m```
Activity
Closes #2182. (#2183)