AdaptyUI-React-Native icon indicating copy to clipboard operation
AdaptyUI-React-Native copied to clipboard

Unable to disable default handling of paywall URLs

Open troberts-28 opened this issue 5 months ago • 1 comments

I want to handle the opening of URLs from the Adapty paywall myself (I want them to open in the in-app browser rather than the system browser), but cannot block the default handler. I have tried returning false/void in the onUrlPress event listener, but that doesn't work. Is there a way to do this? If not, can it be implemented?

package.json

"@adapty/react-native-ui": "2.11.0",
"react-native-adapty": "2.11.1",

onUrlPress Listener

onUrlPress(url) {
    // ideally we would open URL in the in-app browser
    // but could not find a way of blocking Adapty's URL handling
    WebBrowser.openBrowserAsync(url);
},

troberts-28 avatar Sep 19 '24 09:09 troberts-28