0👍
React + TypeScript
You need to change:
import { Chart as ChartJS} from 'chart.js/auto';
to
import 'chart.js/auto';
- Chartjs-Generating different chart results on fly causes flickering
- Chartjs-Unable to create Stacked Grouped Bar Chart with chart.js / react-chartjs-2 in React
-1👍
Chart.js comes with build in typings so you need to uninstall both the types packages then it will work fine.
- Chartjs-How to remove all gridlines and ticks all lines in lines chart in javascript taken from cdn)
- Chartjs-Possible to create quadrant chart with ChartJS, with the "origin" centered at a single point?
Source:stackexchange.com