【发布时间】:2021-01-03 10:19:38
【问题描述】:
在Android中我可以添加javascript接口:
class JsInterface(private val onClose: () -> Unit) {
@android.webkit.JavascriptInterface
fun close() {
onClose()
}
}
...
addJavascriptInterface(JsInterface { this@WebViewActivity.finish() }, "client")
如何在 Flutter WebView 或 InAppWebView 或其他包中相同?
【问题讨论】:
标签: android flutter dart webview