-
Notifications
You must be signed in to change notification settings - Fork 39
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
How to remove the white space when the list reach out to the last item #14
Comments
@sopherwang Good evening ! did you manage to fix it? |
You can fix this by scrollable_positioned_list import 'package:scrollable_positioned_list/scrollable_positioned_list.dart'; const negativeItemCount = 20;
const itemCount = 40;
return ScrollablePositionedList.builder(
itemCount: itemCount + negativeItemCount,
initialScrollIndex: negativeItemCount,
reverse: true,
itemBuilder: (context, i) {
i -= negativeItemCount;
return ListTile(title: Text(i.toString()));
},
); It is also possible to create a pseudo infinite scroll by specifying a very large number |
Hi!!, I have seen your implementation and I wanted to ask you a question. Imagine that you have a list of up to 200 elements, which you are moving as you scroll. Why the ScrollablePositionedList asks me randomly for the number 40? How can it be solved? |
Problem: there is a large white space when the listview reaches out to the last item.
Would be great if anyone can help me to remove the white spaces.
Attached a video:
screencapture-1625080719383.mp4
The text was updated successfully, but these errors were encountered: