XYRefresh
An easy way to use pull-to-refresh
Requirements
- iOS 10.0+
- Xcode 10.1+
- Swift 4.2+
Installation
- Installation with Carthage:
github "RayJiang16/XYRefresh"
- Installation with CocoaPods:
pod 'XYRefresh'
Usage
Quick Start
import XYRefresh
final class TableViewController: UITableViewController {
override func viewDidLoad() {
super.viewDidLoad()
tableView.refresh.header = RefreshNormalHeader { [weak self] in
self?.tableView.refresh.header?.endRefreshing()
}
tableView.refresh.footer = RefreshAutoStateFooter { [weak self] in
self?.tableView.refresh.footer?.endRefreshing()
}
}
}
License
XYRefresh is under MIT license. See the LICENSE file for more info.