Country.fromJson constructor

Country.fromJson(
  1. Map<String, dynamic> json
)

Implementation

factory Country.fromJson(Map<String, dynamic> json) => Country(
      zhCH: json["zhCH"],
      zhHK: json["zhHK"],
      en: json["en"],
      dialCode: json["dialCode"],
      code: json["code"],
      flagUri: json['code'] != null
          ? 'assets/flags/${json['code'].toLowerCase()}.webp'
          : null,
    );