Created
November 5, 2014 16:20
-
-
Save njdehoog/b881e127b17f4d4c03fe to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Person { | |
var name = Observable("John") | |
} | |
let person = Person() | |
person.name.subscribe() { oldValue, newValue in | |
println("name changed: \(oldValue) to \(newValue)") | |
} | |
person.name.value = "Jane" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment