scrollToTop method
void
scrollToTop()
Jumps the scroll position to the top of the scrollable component.
In a vertical scroll component this will scroll to the top of the
scrollable component. In a horizontal scroll component this will scroll
to the left end of the scrollable component.
If the scrollable component's children are in reversed order, this
method will scroll to the bottom or right end of the scrollable
component based on scroll direction.
Example
final scrollController = ScrollController();
scrollController.scrollToTop();
Implementation
void scrollToTop() => jumpTo(0.0);