BuildContextFlutterExtensions extension

on

Methods

defaultTextStyle() DefaultTextStyle
The DefaultTextStyle instance from the closest context.
iconTheme() IconThemeData
The IconThemeData instance from the closest context.
locale({bool nullOk = false}) Locale
The Locale instance from the closest context.
localizations<T>() → T?
The Localizations instance from the closest context.
maybeRead<T>() → T?
Returns the read value if it exists otherwise null.
maybeWatch<T>() → T?
Returns the watch value if it exists otherwise null.
The Navigator instance from the closest context.
showDialog<T>({bool barrierDismissible = true, Color? barrierColor = Colors.black54, String? barrierLabel, bool useSafeArea = true, bool useRootNavigator = true, RouteSettings? routeSettings, required WidgetBuilder builder}) Future<T?>
showGeneralDialog<T>({bool barrierDismissible = true, Color barrierColor = Colors.black54, String? barrierLabel, bool useSafeArea = true, bool useRootNavigator = true, RouteSettings? routeSettings, required WidgetBuilder builder}) Future<T?>
theme() ThemeData
The ThemeData instance from the closest context.