I'm using pub webview_flutter: ^3.0.1 to display webview
However, when the target website displays a pop-up alert it appears as attached:
here
How to override this to display a popup of my own? I already tried
javascriptChannels: Set.from([
JavascriptChannel(
name: 'Alert',
onMessageReceived: (JavascriptMessage message) {
// alert message = Test alert Message
print(message.message);
// TODO popup
},
)
]),
But I'm not receiving any response in that callback method onMessageReceived
Any help will be appreciated. Thanks!