Skip to content

Commit 9103e8f

Browse files
authored
Fix outdated public RefCallback type (#4801)
1 parent 632d5cc commit 9103e8f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/index.d.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ export interface VNode<P = {}> {
3838
export type Key = string | number | any;
3939

4040
export type RefObject<T> = { current: T };
41-
export type RefCallback<T> = (instance: T | null) => void;
41+
export type RefCallback<T> = (instance: T | null) => void | (() => void);
4242
export type Ref<T> = RefCallback<T> | RefObject<T | null> | null;
4343

4444
export type ComponentChild =

0 commit comments

Comments
 (0)