Skip to content

Commit 9d45b70

Browse files
authored
Merge pull request #10 from ace-han/master
update data before options to support Chart.js v3 (beta.11)
2 parents 41cde79 + 6a75aae commit 9d45b70

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/ReactChart.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,8 +38,8 @@ export const ReactChart = ({
3838
const CHART_ID = useMemo(() => generateID('Chart'), []);
3939

4040
useEffect(() => {
41-
chartInstance.current.options = options;
4241
chartInstance.current.data = data;
42+
chartInstance.current.options = options;
4343

4444
chartInstance.current.update(updateMode);
4545
}, [data, options]);

0 commit comments

Comments
 (0)