showAlertDialogAsync()
Displays an alert dialog with the specified content and a single dismiss button.
showAlertDialogAsync(
config:
| MessageDialogOptions
| DeferredString
| string
| StringConvertible[],
buttonText?: StringConvertible,
): Promise<void>;
Notes
- Use fmt to translate content if necessary; this method doesn’t localize strings by default.
Parameters
- config — An instance of MessageDialogOptions; or a callback function to set options for the dialog to be displayed; or one or more messages to be displayed
- buttonText — The text for the dismiss button (if a single message was provided)
Return value
A promise that resolves when the dialog is closed.
Errors
This method throws an error if the modal dialog controller can’t be initialized (i.e. there’s no modal factory or alert dialog builder).
Related
class AppContext
A singleton class that represents the global application state.
