Closed stefandesu closed 6 years ago
The current state could also be stored in the fragment identifier as part of the URL (https://coli-conc.gbv.de/cocoda/#hercomesthestate), see shared state and routing in vue. Client side storage could also be used for caching and as private backend to store mappings - but that's another issue. The question of this issue is:
What is part of the "current state of the application"?
We should use Vue Router for this. It would make sense to use URL query parameters for the selected schemes/concepts and the current mapping. Here is a relevant tutorial: How to make content dynamic via URL query parameters in Vue.
Selected concept schemes and concepts are now added as URL parameters (schemeLeft
, conceptLeft
, schemeRight
, conceptRight
). Leaving this issue open for further discussion and ideas.
The current mapping in MappingEditor should be part of the URL parameters as well.
The current mapping is now part of the URL parameters, although with a few caveats:
All of these except for the last point will be fixed later. I'm not sure if it's possible to actually fix the last point without encoding the whole mapping object. I'll think about it.
uri
.Because of all this, I will (finally) close this issue. Number 1 will be implemented in the next few days.
Client-side (in-browser) storage could be used to preserve the current state of the application even after refreshing the site or restarting the browser. See https://vuejs.org/v2/cookbook/client-side-storage.html.