# UI
pod 'Masonry'
pod 'MBProgressHUD'
pod 'MJRefresh'
pod 'ActionSheetPicker-3.0'
pod 'GKCover'
pod 'UITableView+FDTemplateLayoutCell'
# Tools
pod 'YYKit'
pod 'DateTools'
# Network
pod 'AFNetworking', '~> 3.1.0'
# Image
pod 'SDWebImage', '~> 4.0'
pod 'TZImagePickerController'
#Video
pod 'SJVideoPlayer'
# Text
pod 'DTCoreText', '~> 1.6'
# QCloud
pod 'TICSDK'
1.MJRefresh[上拉下拉刷新]
https://github.com/CoderMJLee/MJRefresh
需要总结下
1.可用方法:
self.questionTableView.mj_header = [MJRefreshNormalHeader headerWithRefreshingBlock:^{
[self.questionTableView.mj_header beginRefreshing];
[self loadNewData];//该方法中mj_header endRefreshing
}];
self.questionTableView.mj_footer = [MJRefreshBackStateFooter footerWithRefreshingBlock:^{
[self.questionTableView.mj_footer beginRefreshing];
[self loadMoreData:self.currentPage+1];//该方法中mj_footer endRefreshing
}];
2.其他
2.JhtFloatingBall[类似京东悬浮球/闭源]
https://github.com/jinht/FloatingBall
3.MBProgressHUD[加载指示器]
https://github.com/jdg/MBProgressHUD
1、该方法必须在主线程中执行
2、可以写个对MBProgressHUD的类目,添加一个方法直接就可以使用;
@interface MBProgressHUD (AllqaExtension)
/**
显示图片和文本
@param showView 显示在的视图
@param text 显示文本
@param image 显示图片
@param i 延时时间隐藏
*/
+(void)showHUDAddedTo:(UIView*)showView withHUDText:(NSString*)text withImage:(UIImage*)image afterDelay:(NSTimeInterval)i;
@end
3.延时执行隐藏或移除
[HUD hideAnimated:YES afterDelay:i];
//或者
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(2 * NSEC_PER_SEC)), dispatch_get_main_queue(), ^{
[HUD removeFromSuperview];
});
4.SJVideoPlayer[视频播放器]
https://github.com/changsanjiang/SJVideoPlayer
5.YYKit[全功能工具框架]
https://github.com/ibireme/YYKit
6. GKCover[弹窗]
https://github.com/QuintGao/GKCover
[GKCover coverFrom:[UIApplication sharedApplication].keyWindow
contentView:payView
style:GKCoverStyleTranslucent
showStyle:GKCoverShowStyleCenter
showAnimStyle:GKCoverShowAnimStyleCenter
hideAnimStyle:GKCoverHideAnimStyleNone
notClick:NO];
将视图添加到UIWindow上曾造成过内存泄漏。
7.XHPKit[不用官方SDK实现微信支付、支付宝支付
]
https://github.com/CoderZhuXH/XHPayKit
8.DateTools[对日期做处理,例如:将时间戳换算为距今天多久]
https://github.com/MatthewYork/DateTools
记得加上plist文件中的语言,不加的话默认是英文
image.png
9.YYModel
YYKit的一个分支
//id类型映射为knowledgeID
+ (nullable NSDictionary<NSString *, id> *)modelCustomPropertyMapper{
return @{@"knowledgeId":@"id"};
}
//数组元素 自动转换为对应类型model
+ (NSDictionary *)modelContainerPropertyGenericClass {
return @{@"second_knowledge" : [KnowledgeListModel class],
@"third_knowledge" : [KnowledgeListModel class]};
}
她的处理数据分别是:
@property (nonatomic, assign) NSInteger knowledgeId; //知识点id
//
@property (nonatomic, strong) NSArray<KnowledgeListModel *> *second_knowledge; //2级知识点列表
@property (nonatomic, strong) NSArray<KnowledgeListModel *> *third_knowledge; //3级知识点列表
10.SDCycleScrollView
https://github.com/gsdios/SDCycleScrollView