onJsAlert property

(Future<JsAlertResponse?> Function(T controller, JsAlertRequest jsAlertRequest)?) onJsAlert
final

Event fired when javascript calls the alert() method to display an alert dialog. If JsAlertResponse.handledByClient is true, the webview will assume that the client will handle the dialog.

jsAlertRequest contains the message to be displayed in the alert dialog and the of the page requesting the dialog.

Officially Supported Platforms/Implementations:

Implementation

final Future<JsAlertResponse?> Function(
    T controller, JsAlertRequest jsAlertRequest)? onJsAlert;