deviceTypeOf static method

DeviceType deviceTypeOf(
  1. double width
)

Implementation

static DeviceType deviceTypeOf(double width) {
  if (width >= xl) return DeviceType.desktop;
  if (width >= lg) return DeviceType.tablet;
  return DeviceType.mobile;
}