mirror of
https://github.com/grafana/grafana.git
synced 2025-02-25 18:55:37 -06:00
DashboardLinks: Fix time in links not being updated (#40934)
This commit is contained in:
parent
24a74cd06e
commit
fadf72dd34
@ -2,6 +2,6 @@ import { useState } from 'react';
|
||||
|
||||
/** @internal */
|
||||
export function useForceUpdate() {
|
||||
const [value, setValue] = useState(0); // integer state
|
||||
return () => setValue(value + 1); // update the state to force render
|
||||
const [_, setValue] = useState(0); // integer state
|
||||
return () => setValue((prevState) => prevState + 1); // update the state to force render
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user