forked from Ivasoft/mattermost-mobile
PostList do not scroll to bottom after the first onEndReached (#6109)
This commit is contained in:
@@ -113,7 +113,7 @@ const PostList = ({
|
|||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
listRef.current?.scrollToOffset({offset: 0, animated: false});
|
listRef.current?.scrollToOffset({offset: 0, animated: false});
|
||||||
}, [channelId, listRef.current]);
|
}, [channelId]);
|
||||||
|
|
||||||
useEffect(() => {
|
useEffect(() => {
|
||||||
const scrollToBottom = (screen: string) => {
|
const scrollToBottom = (screen: string) => {
|
||||||
@@ -352,7 +352,6 @@ const PostList = ({
|
|||||||
keyboardShouldPersistTaps='handled'
|
keyboardShouldPersistTaps='handled'
|
||||||
keyExtractor={keyExtractor}
|
keyExtractor={keyExtractor}
|
||||||
initialNumToRender={INITIAL_BATCH_TO_RENDER + 5}
|
initialNumToRender={INITIAL_BATCH_TO_RENDER + 5}
|
||||||
listKey={`postList-${channelId}`}
|
|
||||||
ListFooterComponent={footer}
|
ListFooterComponent={footer}
|
||||||
maintainVisibleContentPosition={SCROLL_POSITION_CONFIG}
|
maintainVisibleContentPosition={SCROLL_POSITION_CONFIG}
|
||||||
maxToRenderPerBatch={10}
|
maxToRenderPerBatch={10}
|
||||||
|
|||||||
Reference in New Issue
Block a user