observeRouter method
Track navigation from a Listenable router + a current-path getter — e.g. GoRouter (catches shell/nested routes a root observer misses):
nexus.replay.observeRouter(
appRouter.routerDelegate,
() => appRouter.routerDelegate.currentConfiguration.uri.path,
);
Implementation
void observeRouter(Listenable router, String Function() currentPath) =>
_controller.observeRouter(router, currentPath);