Created
July 7, 2017 08:44
-
-
Save SunXiaoShan/4be2950179f65e6165b4073e8360e76e to your computer and use it in GitHub Desktop.
SignalExample2
This file contains hidden or 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
// create a signal | |
RACSubject *subject = [RACSubject subject]; | |
// subscribe notification | |
[subject subscribeNext:^(id _Nullable x) { | |
NSLog(@"content 2:%@", x); | |
}]; | |
// send message | |
[subject sendNext:@"message 2"]; | |
// output | |
// content 2:message 2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment