Skip to content

Commit 371b021

Browse files
useInfiniteScroll-完善滚动自动加载的元素要求 (#1765)
* Update index.zh-CN.md 实现滚动自动加载-完善target元素需要设置固定高度和overflow属性 * Update packages/hooks/src/useInfiniteScroll/index.zh-CN.md Co-authored-by: 砖家 <[email protected]> * Update index.en-US.md Co-authored-by: 砖家 <[email protected]>
1 parent 715f4dc commit 371b021

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

packages/hooks/src/useInfiniteScroll/index.en-US.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ In the data fixation scenario, we sometimes use `page` and `pageSize` to request
3434

3535
In the infinite scrolling scenario, the most common case is to automatically load when scrolling to the bottom. By configuring the following properties, you can achieve scrolling to automatically load.
3636

37-
- `options.target` specifies the parent element
37+
- `options.target` specifies the parent element, The parent element needs to set a fixed height and support internal scrolling
3838
- `options.isNoMore` determines if there is no more data
3939

4040
<code src="./demo/scroll.tsx" />

packages/hooks/src/useInfiniteScroll/index.zh-CN.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@ useInfiniteScroll 的第一个参数 `service` 是一个异步函数,对这个
3434

3535
在无限滚动场景中,我们最常见的是滚动到底部时自动加载。通过配置以下几个属性,即可实现滚动自动加载。
3636

37-
- `options.target` 指定父级元素
37+
- `options.target` 指定父级元素(父级元素需设置固定高度,且支持内部滚动)
3838
- `options.isNoMore` 判断是不是没有更多数据了
3939

4040
<code src="./demo/scroll.tsx" />

0 commit comments

Comments
 (0)