The purpose of the go_router for Flutter is to use declarative routes to reduce complexity, regardless of the platform you're targeting (mobile, web, desktop), handling deep linking from Android, iOS and the web while still allowing an easy-to-use developer experience.
How to do this below for GoRouter
pop a page
Navigator.pop();
pop series of pages until a specific named route.