-
Notifications
You must be signed in to change notification settings - Fork 0
Quick Start
Rayhan Nabi edited this page Sep 2, 2019
·
5 revisions
A quick rundown of the basic usages of RNAlertController
.
RNAlertController(title: "Message", message: "Server time out")
.addOkButton()
.present()
RNAlertController *alert = [[RNAlertController alloc] initWithTitle:@"Message" message:@"Server time out"];
[alert addOkButton];
[alert presentOn:nil completion:nil];
RNAlertController(title: "Message", message: "Server time out")
.addOkButton()
.addCancelButton()
.present()
RNAlertController *alert = [[RNAlertController alloc] initWithTitle:@"Message" message:@"Server time out"];
[alert addOkButton];
[alert addCancelButton];
[alert presentOn:nil completion:nil];
RNAlertController(title: "Message", message: "Server time out")
.addButton(title: "OK", type: .default) { [weak self] in
self?.doSomething()
}
.addButton(title: "Cancel", type: .cancel, action: nil)
.present()
RNAlertController *alert = [[RNAlertController alloc] initWithTitle:@"Message" message:@"Server time out"];
[alert addButtonWithTitle:@"OK", type: AlertButtonTypeDefault action:^{
[self doSomething];
}];
[alert addButtonWithTitle:@"Cancel", type: AlertButtonTypeCancel action:nil];
[alert presentOn:nil completion:nil];
For more usage and customization see related wikis.
Create an issue.
Create a feature request.
For any queries, send me a message at Telegram: @rayhannabi