Latest 0.1.0
Homepage https://github.com/onmyway133/Throttle
License MIT
Platforms ios 8.0, requires ARC
Authors

[![CI Status](http://img.shields.io/travis/Khoa Pham/Throttle.svg?style=flat)](https://travis-ci.org/Khoa Pham/Throttle)
Version
License
Platform

Usage

To run the example project, clone the repo, and run pod install from the Example directory first.

extension ViewController {
    func setupThrottle() {
        throttle = Throttle(interval: 1,
            actionBlock: { [weak self] in
                self?.search()
            }, cancelBlock: {
              // your cancel block handler goes here
        })
    }
}

extension ViewController : UISearchResultsUpdating {
    func updateSearchResultsForSearchController(searchController: UISearchController) {
        throttle.fire()
    }
}

Installation

Throttle is available through CocoaPods. To install
it, simply add the following line to your Podfile:

pod "Throttle"

Author

Khoa Pham, [email protected]

License

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

Latest podspec

{
    "name": "Throttle",
    "version": "0.1.0",
    "summary": "Debounce with Throttle",
    "homepage": "https://github.com/onmyway133/Throttle",
    "license": "MIT",
    "authors": {
        "Khoa Pham": "[email protected]"
    },
    "source": {
        "git": "https://github.com/onmyway133/Throttle.git",
        "tag": "0.1.0"
    },
    "social_media_url": "https://twitter.com/onmyway133",
    "platforms": {
        "ios": "8.0"
    },
    "requires_arc": true,
    "source_files": "Pod/Classes/**/*",
    "resource_bundles": {
        "Throttle": [
            "Pod/Assets/*.png"
        ]
    }
}

Pin It on Pinterest

Share This