I want to listen to changes to $email and $password, and then store the result in signInDisabled, but I'm not sure how to listen to changes from both.
@Published var email = ""
@Published var password = ""
var signInDisabled = true
var session : SessionListenerProtocol
private var cancellables = Set<AnyCancellable>()
init(){
// ???
$email, $password { email, password in
email == "" || password == ""
}
.assign(to: \.signInDisabled, on: self)
.store(in: &cancellables)
}