ChartJS click anywhere to get which y-axis label was clicked?

Viewed 492

We have click event in chart.js which is great. The click event is triggered anywhere we click on the chart. But, the event is undefined if clicked except the dataset. Is it possible to get which y-axis label was clicked?

Here is an example where we get an error if clicked outside the bar? Click event on stacked bar chart - ChartJs

Thanks:)

0 Answers
Related