Dimibe / grouped_list

A Flutter ListView in which items can be grouped into sections.
https://pub.dev/packages/grouped_list
MIT License
395 stars 106 forks source link

List not scrolling to the end #114

Closed bfamzz closed 2 years ago

bfamzz commented 3 years ago

I am using the following code snippet to auto scroll to the end of a list:

SchedulerBinding.instance!.addPostFrameCallback((_) {
      scrollController.animateTo(
      scrollController.position.maxScrollExtent, 
      duration: const Duration(milliseconds: 3), 
      curve: Curves.easeOut
    );
});
return GroupedListView<Chat, DateTime>(
    controller: scrollController,
.
.
.

However, one or two items are not showing until a manual scroll is initiated.

How can I implement auto scrolling to the end of the list?

P.S. the scrolling implementation above works for ListView

Thanks.

glintpursuit commented 2 years ago

@BFamzz did you found the solution ?

bfamzz commented 2 years ago

@glintpursuit I found the answer at the end of the documentation on the ReadME. See the screenshot.

image