Hey All, I have what I hope is a simple question.
I have a custom panel plugin making a REST call using useEffect()
.
As expected, on first render, everything works, but I am struggling on how to get the dashboard refresh to make a new REST call.
For example, setting the page dashboard refresh to 30s, I see the console log I have fire, but how do I correctly get useEffect()
to run to get an update?
Please note: I currently have a dirty hack that increments a counter on a timer, which of course ignores the grafana refresh period.
Gist of the code here: