Skip to content

Commit 25f40f0

Browse files
committed
add resize observer constructor as a dependency in useLayoutEffect
1 parent e490e44 commit 25f40f0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

index.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,7 @@ function useComponentSize(ref, opts) {
6363
}
6464
}
6565
},
66-
[ref.current]
66+
[ref.current, ResizeObserverConstructor]
6767
)
6868

6969
return ComponentSize

0 commit comments

Comments
 (0)