platform property

TargetPlatform? get platform

The running platform

Implementation

static TargetPlatform? get platform {
  if (_platform == null && context != null) {
    _platform = Theme.of(context!).platform;
  }
  return _platform;
}