Skip to content

Instantly share code, notes, and snippets.

@azamsharp
Created October 24, 2017 16:18
Show Gist options
  • Save azamsharp/ba30680d58776df994d1a320190b4ae6 to your computer and use it in GitHub Desktop.
Save azamsharp/ba30680d58776df994d1a320190b4ae6 to your computer and use it in GitHub Desktop.
class ChangePasswordTableViewController : UITableViewController {
private var viewModel :ChangePasswordViewModel = ChangePasswordViewModel()
@IBOutlet weak var newPasswordTextField :BindingTextField! {
didSet {
self.newPasswordTextField.bind { self.viewModel.newPassword.value = $0 }
}
}
@IBOutlet weak var confirmPasswordTextField :BindingTextField! {
didSet {
self.confirmPasswordTextField.bind { self.viewModel.confirmPassword.value = $0 }
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment