Call ApexCharts methods globally using .exec()
masterIf you need to call ApexCharts methods from outside the component context (where you don't have a reference to the Angular component), you can use the global window.ApexCharts.exec() method. You must target the specific chart instance using its chart.id.
// Syntax: window.ApexCharts.exec(chartID, methodName, params)
window.ApexCharts.exec("ng-chart-example", "updateSeries", [
{
data: [40, 55, 65, 11, 23, 44, 54, 33]
}
]);