Leaflet / Leaflet.Editable

Make geometries editable in Leaflet.
http://leaflet.github.io/Leaflet.Editable/doc/api.html
559 stars 197 forks source link

editable:true not recognized as property in MapOptions #195

Open radiothom opened 5 years ago

radiothom commented 5 years ago

I'm trying to use leaflet-editable in my angular project but when I try to instantiate the map by adding the editable: true option, the compiler gives me this error:

Type '{ editable: boolean; }' is not assignable to type 'MapOptions'. Object literal may only specify known properties, and 'editable' does not exist in type 'MapOptions'.

This is the code:

const mo: L.MapOptions = { minZoom: 0, maxZoom: 24, zoomSnap: 1, zoomDelta: 1, zoomControl: false, doubleClickZoom: false, editable: true }; this.map = new L.Map( 'mymap', mo ).setView( [40.6824408, 14.7680961], 13 );

Libs references installed: "leaflet": "^1.5.1", "leaflet-editable": "^1.2.0", "@types/leaflet": "^1.5.5", "@types/leaflet-editable": "^0.7.34"

Kind regards, Francesco

seal707 commented 4 years ago

Hi Francesco,

did you find the solution to the problem

chetex commented 4 years ago

Hi Francesco,

Same problem. Did you find the solution? thanks

radiothom commented 4 years ago

Hi Nacho, I decided to switch to openlayers.

Il mer 8 lug 2020, 18:54 nacho notifications@github.com ha scritto:

Hi Francesco,

Same problem. Did you find the solution? thanks

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/Leaflet/Leaflet.Editable/issues/195#issuecomment-655636923, or unsubscribe https://github.com/notifications/unsubscribe-auth/ALCUOI7D3JUD5ZXA62BY6WLR2SQCPANCNFSM4JFDKTBA .