Present
public protocol Present: class
Declare a method to present alert to the view controller.
-
Present the alert on a given view controller.
Declaration
Swift
func present(in vc: UIViewController, animated flag: Bool, completion: (() -> Void)?)Parameters
vcThe view controller.
flagPass true to animate the presentation; otherwise, pass false.
completionThe block to execute after the presentation finishes.
-
Present the alert on a given view controller. The completion block is nil.
Declaration
Swift
func present(in vc: UIViewController, animated flag: Bool)Parameters
vcThe view controller.
flagPass true to animate the presentation; otherwise, pass false.
-
Present the alert on a given view controller. The animated flag is true, and the completion block is nil.
Declaration
Swift
func present(in vc: UIViewController)Parameters
vcThe view controller.
View on GitHub
Install in Dash
Present Protocol Reference