tkwebview2
tkwebview2 copied to clipboard
js_api not available in tkwebview2
Description:
Currently, js_api is not available in tkwebview2 to pass Python methods or data from JavaScript in the WebView. Although the js_api parameter is passed when creating a WebView2 instance, JavaScript cannot invoke Python functions or send data back to the Python environment.
Expected Behavior:
It should be possible for JavaScript to invoke Python methods and pass data, similar to how it works in other libraries like pywebview. This functionality would allow interaction between JavaScript and Python, such as calling Python functions when a button is clicked in the WebView's HTML.
See https://github.com/Smart-Space/tkwebview please.