CircleMarker is no longer inheriting from Circle in leaflet 1.x. Instead Circleis now inheriting from CircleMarker. Editing options are added to Circle in Leaflet.draw and are thus not available for CircleMarker.
We are also experimenting this issue and we implemented a patch. Check if this works for you (download the repo and build the dist with ./node_modules/.bin/jake build)
How to reproduce
What behaviour I'm expecting and which behaviour I'm seeing
Expecting:
Seeing:
TypeError: layer.editing is undefined
(Firefox) orUncaught TypeError: Cannot read property 'enable' of undefined
(Chromium)Minimal example reproducing the issue
Using jsfiddle.
Possible Reason
CircleMarker
is no longer inheriting fromCircle
in leaflet 1.x. InsteadCircle
is now inheriting fromCircleMarker
. Editing options are added toCircle
in Leaflet.draw and are thus not available forCircleMarker
.