platformName property
String
get
platformName
获取当前平台名称 返回: 'android', 'ios', 'windows', 'macos', 'linux', 'fuchsia', 'ohos', 'web'
Implementation
static String get platformName {
if (kIsWeb) return 'web';
return Platform.operatingSystem.toLowerCase();
}