react-component / react-component/virtual-list
[QUESTION]如何判断已经滚动到了底部
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 814
- Forks
- 171
- Avg merge
- 1h 3m
- Merged PRs (30d)
- 3
Description
我通过ref.current.getScrollInfo拿到的信息很奇怪
我的高度设置的是200,内容高度是动态(获取到的是700),然后滚动到底部的时候scrollInfo.y显示的500,这个500的值应该是内容高度700-高度200.
但是我拿不到这个700的值,我就无法判断是否滚动到底部了
所以getScrollInfo能不能暴露更多的信息?
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the implementation and public API for ref.current.getScrollInfo, then read how the virtual list calculates its viewport and content heights. Confirm which scroll information is currently exposed and define the smallest API change that lets callers determine whether scrolling has reached the bottom. Done means the additional information is available and its behavior is covered by an appropriate test.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- frontend
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100