animateToPage method Null safety

dynamic animateToPage(
  1. {required int page,
  2. int duration = 600}

Animate to mentioned page within given Duration Remember the duration here is the total duration in which it will animate though all pages not the single page


animateToPage({required int page, int duration = 600}) {
  assert(_provider != null,
      "LiquidController not attached to any LiquidSwipe Widget.");
  _provider?.animateToPage(page, duration);