onJsConfirm property

(Future<JsConfirmResponse?> Function(InAppWebViewController controller, JsConfirmRequest jsConfirmRequest)?) onJsConfirm
final

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

jsConfirmRequest contains the message to be displayed in the confirm dialog and the of the page requesting the dialog.

Official Android API: https://developer.android.com/reference/android/webkit/WebChromeClient#onJsConfirm(android.webkit.WebView,%20java.lang.String,%20java.lang.String,%20android.webkit.JsResult)

Official iOS API: https://developer.apple.com/documentation/webkit/wkuidelegate/1536489-webview

Implementation

final Future<JsConfirmResponse?> Function(
        InAppWebViewController controller, JsConfirmRequest jsConfirmRequest)?
    onJsConfirm;