Home > Software design >  How to clear the routes when logout in persistent bottom navigation bar?
How to clear the routes when logout in persistent bottom navigation bar?

Time:02-22

I am using this package enter image description here

enter image description here

CodePudding user response:

got solution try this source

   Navigator.of(context, rootNavigator: true)
                              .pushAndRemoveUntil(
                            MaterialPageRoute(
                              builder: (BuildContext context) {
                                return const UserLogin();
                              },
                            ),
                            (_) => false,
                          );
  • Related