To run the example project, clone the repo, and run pod install
from the Example directory first.
- iOS 9 or newer
AGAlertView is available through CocoaPods. To install it, simply add the following line to your Podfile:
pod 'AGAlertView'
Azat Goktas, azattgoktas@gmail.com
Import The AGAlertView
import AGAlertView
Adding Button.
let button1 = AGButton(frame: .zero, title: "Button1")
AGAlert().showAlert(title: "Hey Yo", subtitle: "Thats it", buttons: button1)
Adding button and custom image. You can simply add action to your button.
let button1 = AGButton(frame: .zero, title: "Button1")
let button2 = AGButton(title: "Button2", selector: #selector(buttonTapped), target: self)
AGAlert().showAlert(title: "Hey Yo", subtitle: "Thats it", buttons: button1,button2, image: UIImage(named: "frog"))
Adding button with type of cancel.
let button1 = AGButton(frame: .zero, title: "Button1")
let button2 = AGButton(title: "Cancel",buttonStyle: .cancel)
AGAlert().showAlert(title: "Hey Yo", subtitle: "Thats it", buttons: button2,button1)
AGAlertView is available under the MIT license. See the LICENSE file for more info.