Open uptonking opened 7 years ago
Well, as far as I remember the upload of the zip file happens with a worker, https://github.com/Charmatzis/react-leaflet-shapefile/blob/master/src/leaflet.shpfile.js#L18
so if you want to load a shp file at default, you have to change it so when the page initializes the worker will load the data.
@Charmatzis , thanks a lot. that solved my 2nd questions.
Would you please update the react-leaflet
from 1.0.1 to 1.1.0 in package.json
, the api has a sight change so the examples didn't work.
I used this lib and run the example demo:
the map dispalys successfully, but When I upload the sample .zip, the error shows in developer console.
It seems to be the problem with the change
react-leaflet
api, would you please updatereact-leaflet-shapefile
toreact-leaflet
v1.1.0 or later. thanks