KRPullLoader 1.3.0

KRPullLoader 1.3.0

LangLanguage SwiftSwift
License MIT
ReleasedLast Release May 2019
SPMSupports SPM

Maintained by Krimpedance.

  • By
  • krimpedance



Version License Platform Download Carthage compatible CI Status


  • Easy-to-use
  • Possibles both of pull refresh and load more.


  • iOS 8.0+
  • Xcode 10.2+
  • Swift 5.0+


To run the example project, clone the repo, and open KRPullLoaderDemo.xcodeproj from the DEMO directory.



KRPullLoader is available through CocoaPods and Carthage. To install it, simply add the following line to your Podfile or Cartfile:

# CocoaPods
pod "KRPullLoader"
# Carthage
github "Krimpedance/KRPullLoader"


(see sample Xcode project in /Demo)

Add views

The simplest way:

let refreshView = KRPullLoadView()
refreshView.delegate = self
tableView.addPullLoadableView(refreshView, type: .refresh)

KRPullLoadView is a simple loading view which consists of UIActivityIndicatorView and UILabel.

The change in the state can be watched by the delegate method.

type has .refresh and .loadMore and can add either of UIScrollView's top and bottom.

Add custom views

You can design loading views freely by making custom UIView in succession to KRPullLoadable protocol

Please refer to KRPullLoadView.swift or HorizontalPullLoadView.swift.


 Handler when KRPullLoaderState value changed.

 - parameter state: New state.
 - parameter type:  KRPullLoaderType.
func didChangeState(_ state: KRPullLoaderState, viewType type: KRPullLoaderType)


This is enum which shows the state of the scrolling.

  // hides the view.
.pulling(offset: CGPoint, threshold: CGFloat)
  // Pulling.
  // `offset` is pull offset (always <= 0).
  // This state changes to `loading` when `offset` exceeded `threshold`.
.loading(completionHandler: ()->Void)
  // Shows the view.
  // You should call `completionHandler` when some actions have been completed.

Contributing to this project

I'm seeking bug reports and feature requests.

Release Note

  • 1.3.0

    • Compatible with Swift 5.0.
    • Add method that pull to refresh programmatically (Only KRPullLoaderType.refresh)
  • 1.2.0

    • Compatible with Swift 4.2.


KRPullLoader is available under the MIT license. See the LICENSE file for more info.