-
Not sure if this is possible easily now. I'd like to have several sets of parameters apply to different routes of the app, with the state of the others stored outside of the querystring when one group is active. Example: Notice in this example I know I can use I can just make a custom hook with a useEffect that looks for changes and writes them to context or another state managemet solution... |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Probably not, the scope of this package is to provide a declarative approach to URL state management, as a 1-1 mapping between the URL and state variables. State updates can temporarily be decoupled from the URL (I just added a demo of the deferred URL update pattern), but internal states will still be synced by key, so any It sounds like your "persistance layer" for non-selected sets of values would be best placed in an external state management solution (Zustand, Jotai, Context etc). |
Beta Was this translation helpful? Give feedback.
Probably not, the scope of this package is to provide a declarative approach to URL state management, as a 1-1 mapping between the URL and state variables.
State updates can temporarily be decoupled from the URL (I just added a demo of the deferred URL update pattern), but internal states will still be synced by key, so any
startDate
update would be propagated to any component watching that key.It sounds like your "persistance layer" for non-selected sets of values would be best placed in an external state management solution (Zustand, Jotai, Context etc).