chartjs / chartjs/chartjs-plugin-datalabels
Critical: Cannot read properties of undefined (reading '_labels') <> Angular 12
- Dominant language
- JavaScript
- Stars
- 920
- Forks
- 507
- PR merge metrics
- No merged PRs in 30d
Description
Here are my chart.js versions:
Error: `Cannot read properties of undefined (reading '_labels')`
Problem statement:
I can't produce the workflow or step-by-step why it creates an issue. I make sure labels are assigned before I load a chart.
Still doesn't understand the exact cause of the issue.
Versions:
```
"chart.js": "3.7.0",
"chartjs-plugin-datalabels": "2.0.0",
```
The full error:
```
core.js:7744 ERROR TypeError: Cannot read properties of undefined (reading '_labels')
at Object.afterDatasetsDraw (chartjs-plugin-datalabels.esm.js:1304:43)
at callback (helpers.segment.js:92:15)
at PluginService._notify (chart.esm.js:4922:19)
at PluginService.notify (chart.esm.js:4909:25)
at Chart.notifyPlugins (chart.esm.js:6047:26)
at Chart._drawDatasets (chart.esm.js:5797:10)
at Chart.draw (chart.esm.js:5768:10)
at chart.esm.js:64:15
at Map.forEach ()
at Animator._update (chart.esm.js:42:18)
```
Is there anything else I should provide to find the issue? I appreciate any help, as it is impacting our production environment charts.
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.