Let's .password an example (rephrased) from the ReactiveCocoa Introduction , which includes: the text fields .password and .passwordConfirm correspond to:
RAC(self.enabled) = [RACSignal combineLatest:@[ RACAble(self.password), RACAble(self.passwordConfirm) ] reduce:^(NSString *password, NSString *passwordConfirm) { return @([passwordConfirm isEqualToString:password]); }];
Here, we know at compile time how many and what things we combine, and it is useful to destroy / map the array to "combine" into several arguments with a reduction block. How about when it doesn't work. For example, if you want:
RAC(self.enabled) = [RACSignal combineLatest:arrayOfSignals reduceAll:^(NSArray *signalValues) {
How do you do this with ReactiveCocoa ?
UPDATE: The accepted answers to the answer help explain what I am missing.
source share