We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent a94dd22 commit b0a54baCopy full SHA for b0a54ba
src/utils/handlers.ts
@@ -1,9 +1,5 @@
1
import { Linking } from 'react-native';
2
3
export const onLinkPress = (url: string) => () => {
4
- try {
5
- Linking.openURL(url);
6
- } catch (e) {
7
- console.warn("URL can't be opened", e);
8
- }
+ Linking.canOpenURL(url).then(() => Linking.openURL(url));
9
};
0 commit comments