Also in iOS, there are many awesome libraries!
Lightbox for iOS
POPSpringAnimation *anim = [POPSpringAnimation animation];
...
[layer pop_addAnimation:anim forKey:@"myKey"];
if (deviceSupportsSkype) {
[[UIApplication sharedApplication] openAppType:SSAppURLTypeSkype
withValue:@"415-555-1212"];
}
if (deviceHasChrome) {
[[UIApplication sharedApplication] openAppType:SSAppURLTypeChromeHTTP
withValue:@"http://www.splinesoft.net"];
}
IntentKit - An easier way to handle third-party URL schemes in iOS apps.
oxen - Observable collection in iOS.
self.array.onCollectionChanged = ^(id<OXNChangeInfo> change) {
self.itemsArray = change.currentArray;
if ([change isKindOfClass:[OXNItemAddedChangeInfo class]]) {
[self.collectionView inserItemAtIndex:[NSIndexPath indexPathForItem:change.index inSection:1]];
}
};
KeepLayout - Easy programmable AutoLayout.
[view keepSize:CGSizeMake(100, 200)];
[view keepInsets:UIEdgeInsetsMake(10, 20, 30, 40)];
[view keepCentered];
KVOController - Super handy KVO.
FBKVOController *KVOController = [FBKVOController controllerWithObserver:self];
[KVOController observe:clock keyPath:@"date" options:NSKeyValueObservingOptionInitial|NSKeyValueObservingOptionNew block:^(ClockView *clockView, Clock *clock, NSDictionary *change) {
// update clock view with new value
clockView.date = change[NSKeyValueChangeNewKey];
}];
rdotm - R.java in iOS!
Chameleon - A Lightweight x Powerful Flat Color Framework
describe(@"Foo", ^{
beforeAll(^{
// All asynchronous matching using `will` and `willNot`
// will have a timeout of 2.0 seconds
[Expecta setAsynchronousTestTimeout:2];
});
if(@"foo should be foo", ^{
expect(@"foo").to.equal(@"foo");
});
it(@"will not be nil", ^{
// Test case where default timeout is used
expect(foo).willNot.beNil();
});
});
NSMutableArray *mockArray = mock([NSMutableArray class]);
[mockArray addObject:@"one"];
[verify(mockArray) addObject:@"one"];
NSArray *mockArray = mock([NSArray class]);
[given([mockArray objectAtIndex:0]) willReturn:@"first"];