Post

Replies

Boosts

Views

Activity

Comment on How To Create Heatmap From Array CLCoordinate2D In A SwiftUI Map
@robnotyou quick question. Since MKMapView doesnt require a binding to region, my map shows empty blue (probably in the middle of the sea). @State private var region = MKCoordinateRegion() MapView(region: region) .edgesIgnoringSafeArea(.all) .onAppear() {     region = ... array of CLLocationCoordinate2D } This used to work when it was Map since i just had to go $region since the parameter required has to be binding but now it is not. How can it re-render once the region variable is set?
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Oct ’22