Latest 1.0.0
Homepage https://github.com/liuhaoliang/HLAlert
License MIT
Platforms ios 8.0, requires ARC
Frameworks UIKit
Authors

Introduction

An easy way to use AlertView and ActionSheet in your Object-C or Swift project,this library are based on UIAlertViewController.

demo.gif]

Usage:

  1. add the repo in your podfile
  2. use pod ‘HLAlert’ or drag the library into your project folder
    • Use Object-C

  3. import the header

    #import <HLAlert/HLAlert-Swift.h>
  4. write the method
    [HLAlert showAlertWithTitle:@"title" message:@"message" actionTitles:@[@"action1",@"action2"] handler:^(NSInteger idx) {
        //do something
    }];
    • Use Swift

  5. import the header
    import HLAlert
  6. write the method
    HLAlert.showAlert(title: "title", message: "message", actionTitles: ["action1","action2"]) { (idx) in
            // do something
        }

Latest podspec

{
    "name": "HLAlert",
    "version": "1.0.0",
    "summary": "An easy way to use UIAlertView and UIActionSheet.",
    "description": "u7b80u5355u65b9u4fbfu5730u4f7fu7528UIAlertViewControlleru6784u5efaAlertViewu548cActionSheet",
    "homepage": "https://github.com/liuhaoliang/HLAlert",
    "license": "MIT",
    "authors": {
        "lhl": "[email protected]"
    },
    "platforms": {
        "ios": "8.0"
    },
    "source": {
        "git": "https://github.com/liuhaoliang/HLAlert.git",
        "tag": "1.0.0"
    },
    "source_files": [
        "HLAlert",
        "HLAlert/*.{swift}"
    ],
    "frameworks": "UIKit",
    "requires_arc": true
}

Pin It on Pinterest

Share This