I am trying to access a Grafana variable carrying a timestamp in a script inside a text panel. Honestly I am not sure if this is even possible. This is the script where I would like to replace the timestamp string with a variable I have defined as "lastseen" which is constantly updated by the relevant query.
<div id="timeDiffContainer"></div>
<script>
var yourDateTimeVar = "2023-07-27T12:05:18.788Z";
var ..........
</script>
Is that possible? I did try with all sort of braces but no luck!