2

I use Leaflet draw to draw markers and polygons on a map. The created features are saved to two separate feature groups. One feature group for the markers and one for the polygons. Now I want to edit the features. How can I add two feature groups as editable layers:

'edit': {
  'featureGroup': featureGroupMarker, featureGroupPolygon
}
2

I ended up solving it by adding twice the Leaflet drawControl to the map. One time for markers and one time for the polygons. This way I can specify which layer should be edited.

2

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.