Post

Replies

Boosts

Views

Activity

Reply to Captured previous value in onChange is equal to the new value not the old value
A good alternative to get old values is to use 'willSet' @State private var isSubscribed = false {     willSet {        print("oldValue: \(isSubscribed)")     }   }
Topic: UI Frameworks SubTopic: SwiftUI Tags:
Replies
Boosts
Views
Activity
Aug ’21