Leaflet / Leaflet.draw

Vector drawing and editing plugin for Leaflet
https://leaflet.github.io/Leaflet.draw/docs/leaflet-draw-latest.html
MIT License
1.98k stars 994 forks source link

Deprecated use of _flat, please use L.LineUtil.isFlat instead. #988

Open renderpci opened 4 years ago

renderpci commented 4 years ago

How to reproduce

you can see that the _flat is deprecated by Leaflet:

Deprecated use of _flat, please use L.LineUtil.isFlat instead.

ye | @ | leaflet.js:5 _defaultShape | @ | leaflet.draw.js:8 _initMarkers | @ | leaflet.draw.js:8 addHooks | @ | leaflet.draw.js:8 (anonymous) | @ | leaflet.draw.js:8 _eachVertexHandler | @ | leaflet.draw.js:8 addHooks | @ | leaflet.draw.js:8 enable | @ | leaflet.js:5 _enableLayerEdit | @ | leaflet.draw.js:9 eachLayer | @ | leaflet.js:5 addHooks | @ | leaflet.draw.js:9 enable | @ | leaflet.js:5 enable | @ | leaflet.draw.js:9   | s | @ | leaflet.js:5

indigoxela commented 2 years ago

This issue should get a higher priority, as _flat has just been removed. See https://github.com/Leaflet/Leaflet/pull/8537

This means the next Leaflet release (be it 1.9.3 or 2.0) will definitely break Leaflet.draw.