understanding of React hooks lifecyclebasic knowledge of useEffect cleanup
初心者向け度初回貢献者にどれだけ取り組みやすいかを 1-100 で推定したスコアです。
50
調査方針
Investigate the useInfiniteScroll hook implementation, specifically the setTimeout call that triggers scrollMethod. The issue suggests that when the component unmounts before the timeout fires, the condition becomes permanently true causing infinite loadMore calls. Check the cleanup logic in the useEffect and ensure that the timeout is cleared on unmount. Look at the return statement of the effect to see if clearTimeout is called. The relevant file is likely `src/useInfiniteScroll/index.ts` or similar. Also review any existing comments or related PRs for proposed fixes.
useInfiniteScroll 在第一次请求还未返回时,快速切换到其他组件,会造成无限循环的请求 · alibaba/hooks#2579 | Good First Issue