9.0 Released! → Native ESM runtimes 🚀, Vite support ⚡️, multi-window apps and more...
Read Announcement

Call Signature

ts
function action(
   message: string, 
   cancelButtonText: string, 
actions: string[]): Promise<string>;

Defined in: ui/dialogs/index.d.ts:129

The action() method displays a action box that prompts the visitor to choose some action.

Parameters

ParameterTypeDescription
messagestringThe text to display in the dialog box.
cancelButtonTextstringThe text to display in the cancel button.
actionsstring[]List of available actions.

Returns

Promise<string>

Call Signature

ts
function action(options: ActionOptions): Promise<string>;

Defined in: ui/dialogs/index.d.ts:135

The action() method displays a action box that prompts the visitor to choose some action.

Parameters

ParameterTypeDescription
optionsActionOptionsThe options for the dialog box.

Returns

Promise<string>

Previous
_setResolver