3

I am working on react-native mobile app both ios and android. In my app, i need to use GPS location services. if location services turn off I need to automatically navigate app screen to platform location settings page. I can able to achieve this in android using NativeModules. Now I need to do this on ios also.

Android :

NativeModules.OpenSettings.openNetworkSettings(data => {
  this.setState({
    locationEnabled : false
  })
});

I need help, to enable location services in ios.

Arasuvel
  • 2,971
  • 1
  • 25
  • 40
Sathish Sundharam
  • 1,060
  • 2
  • 12
  • 22

1 Answers1

4

i found a temporary solution to this issue.

Linking.openURL('app-settings:');
Sathish Sundharam
  • 1,060
  • 2
  • 12
  • 22
  • This opens my app's settings. This doesn't open "Location Services" like this does on iOS 10 - https://stackoverflow.com/q/52301580/1828637 - do you know a solution for this on iOS 11? – Noitidart Sep 28 '21 at 01:51