makinacorpus / Leaflet.FileLayer

Loads files locally (GeoJSON, KML, GPX) as layers using HTML5 File API
http://makinacorpus.github.io/Leaflet.FileLayer/
MIT License
270 stars 91 forks source link

Add MapBox's omnivore support #11

Open leplatrem opened 10 years ago

MuellerMatthew commented 8 years ago

I am not sure that specifically targeting omnivore is the best option, i think it would be better to expose the call to the parsing function, and allow users to point it to any parser they choose.
I think we can add an option which can be changed on initialization so that you can alter the parser with the ones you want(including omnivores) i.e. 'omnivore.csv.parse()', 'omnivore.wkt.parse(), etc by either replacing the current parser list, or extending it with custom file types. If we did this we would also want to change the options.formats on the button so it uses all of the parser formats passed to the parser.

Let me know your thoughts, i think this is a good enhancement.