Closed timburgess closed 6 years ago
I've resolved this by reaching into the internals. So for my code which extracts latlngs from layers, I now do a check for getLatlngs
and if not present, I extract from the internals. This is just for single uploads.
var latlngs;
if (typeof layer.getLatLngs === 'function') {
latlngs = layer.getLatLngs()[0];
} else {
latlngs = Object.values(layer._layers)[0]._latlngs[0]
}
I have an example KML file uploading and being displayed. Very cool. But I'm wondering how to reference the lat/lngs in the returned layer object..
Looking at the layer properties I can't see any means to reference the lat/lngs.