-
Notifications
You must be signed in to change notification settings - Fork 148
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Table is pushed down after finish loading #38
Comments
Hi @ndduong97, Currently I use #31 adds a fix to make it possible to use |
The fix has landed in 0.9.0. README has been updated with the code snippet. Pretty much what you have to do is update table view and the run Here is a snippet in Objective-C: // setup infinite scroll
[self.tableView addInfiniteScrollWithHandler:^(UITableView* tableView) {
//
// fetch your data here, can be async operation,
// just make sure to call finishInfiniteScroll in the end
//
NSArray<NSIndexPath *> * indexPaths; // index paths of updated rows
// make sure to update tableView before calling -finishInfiniteScroll
[tableView beginUpdates];
[tableView insertRowsAtIndexPaths:indexPaths withRowAnimation:UITableViewRowAnimationAutomatic];
[tableView endUpdates];
// finish infinite scroll animation
[tableView finishInfiniteScroll];
}]; |
@pronebird Thank you very much for the response! I am using
The EDIT: I did try to remove the table fade in animation but it still doesn't work |
@ndduong97 do you use refresh control at the same time? I wonder if they conflict somehow... |
I used pull down refresher library from yalantis as well. I fixed it by moving the table.reloadData before finishInfiniteScroll |
@ndduong97 that makes sense. I guess |
Hi, I am new to iOS development. My table view is pushed down every time the scroll to bottom loading indicator is finished. So instead of showing the next cell at the space that the loading indicator was at, the whole table is pushed back down.
As a result, the user would have to scroll down to see the new cell. I want to achieve something like the demo you provided. When the user scrolls down, the new cell would show behind the loading indicator. Is there something I should do to achieve this effect?
The text was updated successfully, but these errors were encountered: