navigateTo static method
Implementation
static Future<dynamic> navigateTo(
{Widget? page, GlobalKey<NavigatorState>? navigationKey}) {
if (navigationKey == null) {
return _navigationKey.currentState!.push(MaterialPageRoute(
builder: (context) => page ?? ConnectivityScreen()));
} else
return navigationKey.currentState!.push(MaterialPageRoute(
builder: (context) => page ?? ConnectivityScreen()));
}