在使用react hooks时, 会遇到这样的问题 const [count, setCount] = useState(1) useEffect(() => { setInterval(() => { console.log(count) }, 1000) //闭包陷阱 } ...
確定! 回上一頁