mirror of
https://github.com/VictoriaMetrics/VictoriaMetrics.git
synced 2024-11-23 20:37:12 +01:00
vmui: fix query params saving in URL (#3104)
This commit is contained in:
parent
3af24a5b7c
commit
1304824201
@ -24,7 +24,7 @@ export const StateProvider: FC = ({children}) => {
|
|||||||
const [state, dispatch] = useReducer(reducer, initialPrepopulatedState);
|
const [state, dispatch] = useReducer(reducer, initialPrepopulatedState);
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
if (pathname !== router.dashboards || pathname !== router.home) return;
|
if (pathname !== router.dashboards && pathname !== router.home) return;
|
||||||
setQueryStringValue(state as unknown as Record<string, unknown>);
|
setQueryStringValue(state as unknown as Record<string, unknown>);
|
||||||
}, [state, pathname]);
|
}, [state, pathname]);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user