Closed mtabdar closed 5 years ago
No it's not - this helps with configuring the tile layers that are shown on the OSM site.
Sorry I'm wrong - the data layer support is in this module as well, so yes you can - see https://github.com/openstreetmap/leaflet-osm#data-layer for an example.
thanks for the quick reply. unfortunately i could not make it work. let me explain my question: i have an osm file (exported from openstreetmaps site) and want to show it on a leaflet map and i am not connected to web.
It's fairly simple - you take the XML and call:
var layer = new L.OSM.DataLayer(xml).addTo(map);
How you load the XML into the xml
variable is up to you - that is a general "how do I write javascript" question and nothing specific to this module.
hi, i wonder if it is possible to load .osm file into a leaflet map using this js?