You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I ran into type error when using useResizeObserver hook to observe a div element size
I think useResizeObserver should accept a null value; otherwise, we have to either disable TypeScript checking there or create a dummy div as the initial value for useRef.
To Reproduce
Add a useRef hook to component
Add useResizeObserver
Expected behavior
useResizeObserver shouldn't complains about null value of ref