问题处理
flushSync 退出批量更新
react18,将所有事件都进行批处理,多次 setState 会被合并为 1 次执行;import { useEffect, useState } from "react"; import { fl
lhh|07/31/2024 14:22
问题处理
useEffect 传入函数依赖
import { useEffect, useState } from "react" export default () => { const [v, setV] = useState(fal
lhh|07/31/2024 14:21
博主很懒,就这么多啦~~