getRealtimeWeatherByCityName method
Fetch Realtime API data by city name.
Implementation
Future<RealtimeWeather> getRealtimeWeatherByCityName(String cityName,
{bool airQualityIndex = false}) async {
Map<String, dynamic>? jsonResponse =
await _sendRequest<Map<String, dynamic>>(APIType.realtime,
cityName: cityName, airQualityIndex: airQualityIndex);
return RealtimeWeather(jsonResponse!);
}