Module: libs/common/ide/util/messages
Functions
showError
▸ showError(messages
, id
, message
, ...options
): Promise
<string
| undefined
>
Displays a error message {@link message} to the user along with possible {@link options} for them to select.
Parameters
Name | Type | Description |
---|---|---|
messages | Messages | - |
id | string | Each code site where we issue a error should have a unique, human readable id for testability, eg "deprecatedPositionInference". This allows us to write tests without tying ourself to the specific wording of the error message provided in {@link message}. |
message | string | The message to display to the user |
...options | string [] | A list of options to display to the user. The selected option will be returned by this function |
Returns
Promise
<string
| undefined
>
The option selected by the user, or undefined
if no option was
selected
Defined in
libs/common/ide/util/messages.ts:40
showInfo
▸ showInfo(messages
, id
, message
, ...options
): Promise
<string
| undefined
>
Displays an informational message {@link message} to the user along with possible {@link options} for them to select.
Parameters
Name | Type | Description |
---|---|---|
messages | Messages | - |
id | string | Each code site where we issue a message should have a unique, human readable id for testability, eg "deprecatedPositionInference". This allows us to write tests without tying ourself to the specific wording of the info message provided in {@link message}. |
message | string | The message to display to the user |
...options | string [] | A list of options to display to the user. The selected option will be returned by this function |
Returns
Promise
<string
| undefined
>
The option selected by the user, or undefined
if no option was
selected
Defined in
libs/common/ide/util/messages.ts:63
showWarning
▸ showWarning(messages
, id
, message
, ...options
): Promise
<string
| undefined
>
Displays a warning message {@link message} to the user along with possible {@link options} for them to select.
Parameters
Name | Type | Description |
---|---|---|
messages | Messages | - |
id | string | Each code site where we issue a warning should have a unique, human readable id for testability, eg "deprecatedPositionInference". This allows us to write tests without tying ourself to the specific wording of the warning message provided in {@link message}. |
message | string | The message to display to the user |
...options | string [] | A list of options to display to the user. The selected option will be returned by this function |
Returns
Promise
<string
| undefined
>
The option selected by the user, or undefined
if no option was
selected