Variables
Use the replaceVariables()
function to replace Dashboard and Global variables.
const email = replaceVariables("${__user.email}");
To learn about three types of variables take a look at Variables.
Replace Variables
In the following example, we replaced the series's name with a value from the variable.

Example
docs/volkovlabs-echarts-panel/replace.js
loading...
Update Variables
Dashboard variables can be updated in the Event Handlers, where
name
is the name of the variables. Addvar-
to update the variable value in the URL.value
is the updated value.
echartsInstance.on("click", (params) => {
locationService.partial({ "var-name": value }, true);
});