Skip to content

Commit ee2a467

Browse files
committed
fix: correct useRef type for animation frame
1 parent 91b296b commit ee2a467

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

apps/hub/src/components/spline/useSplineBlockchain.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -84,8 +84,8 @@ export function useSplineBlockchain({
8484
variableNames = {},
8585
onUpdate,
8686
}: UseSplineBlockchainOptions) {
87-
const lastUpdateRef = useRef<number>(0);
88-
const animationFrameRef = useRef<number>();
87+
const lastUpdateRef = useRef(0);
88+
const animationFrameRef = useRef<ReturnType<typeof requestAnimationFrame> | null>(null);
8989

9090
// Merge variable names with defaults
9191
const varNames = { ...DEFAULT_VARIABLE_NAMES, ...variableNames };

0 commit comments

Comments
 (0)