Check if a specific application is installed on the device using React Native

From my application, I am trying to check if another application is installed (in my example, Google Maps). So I tried using:

Linking.canOpenURL('comgooglemaps://?daddr=' + address + '&directionsmode=walking').then(supported => {...}).catch(err => console.error('An error occurred', err)); 

But it returns that it is not supported, so Google Maps is not installed. Do you know a way to solve this problem?

+6
source share
1 answer

I assume you have this issue with iOS.

Starting with iOS 9, you must declare the URL scheme you want to use. See this answer for details .

Or white paper: https://developers.google.com/maps/documentation/ios-sdk/start#step_7_declare_the_url_schemes_used_by_the_api

+1
source

All Articles