-
Notifications
You must be signed in to change notification settings - Fork 57
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
createLayer function #156
Comments
@KubaLorenc I think we need to decide what the use case for this is. The purpose of It also might be possible to achieve the same thing with ServiceWorkers which could intercept the network requests. |
@patrickarlt @dpraimeyuu @axelio Hi, thanks for your reply:) |
@KubaLorenc it seems like in maplibre/maplibre-gl-js#207 (comment) it was recommended to solve the problem of tile access offline with a ServiceWorker. Looking at your code I don't really see any reason why it shouldn't work. Without a specific example or error messages I don't have much to go on. The main benefit of using a ServiceWorker would be that Service workers are designed to transparently intercept and modify network requests which is exactly what you want to do:
I don't think anything would be required in this library if you used ServiceWorkers to do this. |
Describe the problem
In esri-leaflet, when we create tile using esriLeaflet.tiledMapLayer({options}), we can actually override the createTile function and for example fetch data from local storage instead of api. Unfortunatelly I don't see how we could do that with esri-leaflet-vector, since esriLeaflet.vectorTileLayer() doesn't seem to trigger createTile . Is there any equivalent of createTile for the VectorTileLayer class?
Describe the proposed solution
Solution would be to provide info of what function is triggered to fetch data from api
Edit:
there is a thread on maplibre github concernig this problem: maplibre/maplibre-gl-js#29
I tried to wire that into the MaplibreGLJSLayer in _initGL function but with little luck
Alternatives considered
No response
Additional Information
No response
The text was updated successfully, but these errors were encountered: