animToTop method

Future<void> animToTop({
  1. dynamic milliseconds = 300,
})

Scroll to top with given animation duration

Implementation

Future<void> animToTop({milliseconds = 300}) async {
  animateTo(
    0,
    duration: Duration(milliseconds: milliseconds),
    curve: Curves.decelerate,
  );
}