of static method

ThemeData of(
  1. BuildContext context
)

Implementation

static ThemeData of(BuildContext context) =>
    context.dependOnInheritedWidgetOfExactType<_InheritedTheme>()?.data ??
    ThemeData._fallbacks.putIfAbsent(defaultTargetPlatform, ThemeData.new);