diff --git a/app/page.js b/app/page.js index 119294e..36b3def 100644 --- a/app/page.js +++ b/app/page.js @@ -239,6 +239,7 @@ const FollowPostList = forwardRef(({ scrollHeight }, ref) => { left: 0, behavior: "smooth", // 可选,平滑滚动效果 }); + // setFollowPostList([]); await getFollowPostList(ids.current, 0); } async function loadMore() { @@ -288,8 +289,7 @@ const FollowPostList = forwardRef(({ scrollHeight }, ref) => { } else { setFollowPostList((old) => { - if(followsResponse.data.offset==4){ - + if(!offset){ return followsResponse.data.list; }else{ return [...old, ...followsResponse.data.list] @@ -321,8 +321,8 @@ const FollowPostList = forwardRef(({ scrollHeight }, ref) => { ))} {!followPostList?.length && (