Post

Replies

Boosts

Views

Activity

Following "Meet WeatherKit"- getting async error
'async' call cannot occur in a global variable initializer for weather variable. import WeatherKit import CoreLocation let weatherService = WeatherService() let chicago = CLLocation(latitude: 47, longitude: 87.58293) let weather = try! await weatherService.weather(for: chicago) let temperature = weather.currentWeather.temperature
Replies
1
Boosts
0
Views
874
Activity
May ’23