getData method
void
getData()
Implementation
void getData() {
print("start getData");
busy = true;
subject
.addStream(Stream.fromFuture(futureFunction(pageKey)))
.then((value) => busy = false);
print("end addStream getData");
scrollController.addListener(() {
if (scrollController.offset >=
scrollController.position.maxScrollExtent &&
!scrollController.position.outOfRange) {
fetchData();
} else if (scrollController.offset <=
scrollController.position.minScrollExtent &&
!scrollController.position.outOfRange) {
debugPrint("reached the Top");
} else {
debugPrint("else");
}
});
// Future.delayed(const Duration(seconds: 1)).then((value) => paginationHelper
// .controller
// .listen((notification) => fetchData(notification)));
}