0👍
From the code mentioned above , what I understand is you are importing directives from ng2-charts library inside Module.
probably this is the cause you are having error.
Try importing module :
import { ChartsModule } from 'ng2-charts/ng2-charts';
// In your App's module:
imports: [
ChartsModule
]
Hope this helps.
0👍
I had the same problem. I added this to my system.config.js
file to fix the problem:
map: {
ng2-charts': 'npm:ng2-charts'
'ng2-charts': {
defaultExtension: 'js'
}
- Chartjs-How to use chart.js with knockout.js to create dynamic charts
- Chartjs-Saving ChartJS chart showing all tooltips
Source:stackexchange.com