Hijack webview link clicks. Useful for opening “unrecognized” URLs from, eg., iframes, in Safari.
Function to execute when the webview tries to navigate to an absolute URL.
const {HijackWebviewLinkClick} = window.cordova.plugins;
HijackWebviewLinkClick.listen((url) => {
window.open(url, '_blank');
});
Deactivates hijacking.
const {HijackWebviewLinkClick} = window.cordova.plugins;
HijackWebviewLinkClick.deactivate();