-
Tanner Linsley who is advocating for storing the application state in the URL hinted (Example) a few times that he has a migration concept that allows to update old URL configs to a new structure with a migration concept. I wonder, how a library like next-usequerystate could help with this kind of migrations. I am have some very basic code that …
However, both are not great and not really migrations, just preventing the worst invalid states… Maybe this is something for the roadmap? |
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
While looking into #404 I thought of possible ways to support this idea of migrations. But first… UseCaseWhenever we have a complex URL (like an object)
In both cases, I want to rescue as much information as possible from the object and update the URL with a new, valid object. Example In my case, the object holds which UI elements are active and how they are configure. However, the UI elements can chance. I need to remove/ignore parts of the URL object. Or the UI configuration options can change, which means I need to update the object as well. Current issueRight now, I have no way to access the current URL param inside the Possible solution A: Add a callback to
|
Beta Was this translation helpful? Give feedback.
-
To close this of, I found a solution that I like with the help of @franky47. The working version can be found at https://github.com/FixMyBerlin/atlas-app In short…
Two things about the middleware…
|
Beta Was this translation helpful? Give feedback.
To close this of, I found a solution that I like with the help of @franky47. The working version can be found at https://github.com/FixMyBerlin/atlas-app
In short…
Two things about the middleware…