Style state management in local storage #1747
Closed
JinIgarashi
started this conversation in
Ideas
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Currently, GeoHub uses svelte store to save LayerList and maplibre map object in the memory. If user move to another page from the map, their working data will be destroyed. It would be nice if we can store those states in local storage and restore them when they come back to map editor.
local storage keys
layer-list-{host name}$layerListvariablemap-style-{host name}map-style-id-{host name}stylequery paramIn map editor
LayerList.svelteStore every change on $layerList and maplibre style to local storage
When the page is mounted
stylequery param in URLstylequery paramstylequery param in URLWhen user is leaving from map
Nothing to do?
When user share map
Beta Was this translation helpful? Give feedback.
All reactions