The useRef always returns a current object. To get the actual HTML element, you need to do ref.current: useEffect(() => { if (ref) { console.log("ref", ...
確定! 回上一頁