Skip to content
😊 Goku is an alert view written by swift 3, support both action sheet and alert view style.
Swift Shell Objective-C Ruby
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
Example
Gif
Goku.xcodeproj
Goku
GokuTests
.gitignore
.swift-version
Goku.podspec
LICENSE
README.md

README.md

Goku

Goku is an alert view written by swift 3, support both action sheet and alert view style. And now provide 6 styles to show your alert. If you want to use the world of Swift 3, you need Xcode 8+.

Screenshots

GIF GIF GIF

Easy to use

Provide a default theme of alert view. So you can use this default theme or create a theme you like.

import Goku

// 🌟 Usage πŸ‘‡
	
self.goku.presentAlert(animated: true, closure: { (make) in
	make.theme
		.actionSheet
		.title("Okay/Cancel")
		.message("A customizable action sheet message.")
		.cancel("Cancel")
		.destructive("OK")
		.normal(["Button1", "Button2"])
		.tapped({ (index) in
		    print("Tapped index is \(index)")
		}
	)
})	

self.goku.presentAlert(animated: true, closure: { (make) in
	make.theme
		.alert
		.success
		.title("Congratulations!")
		.message("You've just displayed this awesome Pop Up View.")
		.cancel("Cancel")
		.normal(["Default 1", "Default 2"])
		.tapped({ (index) in
		    print("Tapped index is \(index)")
		}
	)
})

For more usage you can see Example

Icon image from SCLAlertView

Installation

Goku is available through Cocoapods.

Add the following line to you Podfile

pod 'Goku', '~> 1.0'

TODO

  • More animation
  • More beautiful syntax
  • Usage like SnapKit

License

Goku is released under the MIT license. See LICENSE for details.

You can’t perform that action at this time.