clearAll static method

void clearAll({
  1. BuildContext? context,
})

Implementation

static void clearAll({BuildContext? context}) {
  final state = navigatorState(context);
  while (state?.canPop() == true) {
    state?.pop();
  }
}