Skip to content

Commit c82d391

Browse files
committed
Commit chart runtime ref updates
1 parent 6192b44 commit c82d391

1 file changed

Lines changed: 7 additions & 2 deletions

File tree

src/components/charts/ChartsCatalogChart.tsx

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,8 +48,13 @@ export function ChartsCatalogChart({
4848
const [visible, setVisible] = React.useState(!defer)
4949
const [failed, setFailed] = React.useState(false)
5050

51-
inputRef.current = { height, interactive, revision }
52-
onStatusRef.current = onStatus
51+
React.useEffect(() => {
52+
inputRef.current = { height, interactive, revision }
53+
}, [height, interactive, revision])
54+
55+
React.useEffect(() => {
56+
onStatusRef.current = onStatus
57+
}, [onStatus])
5358

5459
React.useEffect(() => {
5560
const container = containerRef.current

0 commit comments

Comments
 (0)