animateScroll method

Future<void> animateScroll({
  1. double alignment = 0.0,
  2. Duration? duration,
  3. Curve curve = Curves.ease,
  4. ScrollPositionAlignmentPolicy alignmentPolicy = ScrollPositionAlignmentPolicy.explicit,
})

Implementation

Future<void> animateScroll({
  double alignment = 0.0,
  Duration? duration,
  Curve curve = Curves.ease,
  ScrollPositionAlignmentPolicy alignmentPolicy =
      ScrollPositionAlignmentPolicy.explicit,
}) async {
  return await currentContext!.animateScroll(
    alignment: alignment,
    duration: duration,
    curve: curve,
    alignmentPolicy: alignmentPolicy,
  );
}