CocoaPods trunk is moving to be read-only. Read more on the blog, there are 4 months to go.

AlertEasily 1.1.0

AlertEasily 1.1.0

TestsTested
LangLanguage SwiftSwift
License MIT
ReleasedLast Release Dec 2017
SwiftSwift Version 3.0
SPMSupports SPM

Maintained by MZC0829.



  • By
  • maizhichao

AlertEasily

Easy to show UIAlertController, written in Swift.

Cocoapods

1. Add the following line to your Podfile:

platform :ios, '8.0'

target 'YourIosApps' do

  use_frameworks!

  pod 'AlertEasily', '~> 0.0.3'

end

2. Then, run the following command:

$ pod install

Requirements

  • iOS 8.0+
  • swift 3+ and swift 4

Usage

- just like

showAlert(title: "This is AlertEasily")

- or

showAlert(title: "AlertEasily", message: "This is AlertEasily", preferredStyle: .alert, defaultHandler: {
            
            print("clicked default action")
            
        }, cancelHandler: nil)

- or

showAlert(title: "AlertEasily", message: "This is AlertEasily", preferredStyle: .alert, defaultHandler: {

            print("clicked default action")

        }) {

            print("clicked cancel action")
        }