device_friendly_name 1.0.2
device_friendly_name: ^1.0.2 copied to clipboard
Retrieve a friendly name for the current device
device_friendly_name #
Retrieve a device's friendly name, such as "Bob's iPhone" or "Galaxy S9 (Sarah)".
Usage #
- Add
device_friendly_nameto your dependencies inpubspec.yaml - Import via
import 'package:device_friendly_name/device_friendly_name.dart'; - Accessing
DeviceFriendlyName.getDeviceFriendlyNamereturns a Future that resolves to your device name. This name might be empty, so be sure to have a fallback just in case.
See the example\lib\main.dart for sample code.