adding decompression of gzipped files#52
Conversation
|
Nice :) I think that this is a little bit out of scope for this tiny tool though. We should use this use-case to introduce the necessary «hooks» to allow to support decompression, as you did, but not merge it with the plugin code. What do you think ? |
|
Thank you for your idea. |
|
We could add an API to add custom parsers. For example: gzipParser = {
extensions: ['.gzip'],
read: function (fileReader) {
return fileReader.readAsArrayBuffer()
},
toGeoJSONString: function(data) {
// ... your custom gzip code
}
}
L.FileLayer.FileLoader.addParser(gzipParser);It would require some refactor here and there, but I think it would be beneficial for the existing code too. What do you think? |
|
Very much in favour of an API to add custom parsers. I would want to add shp/xml/csv parsers but for the moment these all reside in separate plugins with overlapping functionality. Do you need any help to add that? |
I don't contribute to this library anymore. But would be glad to review/test if someone submits some code :) |
|
New PR: #56 |
No description provided.