API to open app settings

import { Linking } from “react-native”;

Linking.openSettings();

Is this same as expo-linking and does it not need same Platform.Version logic?

Does anyone have an updated/latest way of best doing this with Expo SDK 45?
It seems that ACTION_APPLICATION_DETAILS_SETTINGS doesn’t exist anymore and got renamed?

is simply doing Linking.openSettings() enough for it to work on all platforms and older versions?

Here’s the latest info:

SDK 45:

EDIT: It looks like this change was made as part of Expo SDK 44.

Based on the example and @outatime’s post, the startActivityAsync call should look something like this:

import { startActivityAsync, ActivityAction } from 'expo-intent-launcher';
// [...]
startActivityAsync(ActivityAction.APPLICATION_DETAILS_SETTINGS, {
  data: `package:${bundleIdentifier}`,
});

The above works for me on Android 9. I’ve also tested Linking.openSettings() and that also works for me on Android 9. Sorry, I don’t know what other versions they may or may not work on.

If you don’t get any better answers, you might need to try Linking.openSettings() on as many Android and iOS versions you can get your hands on in emulators/simulators and real devices. If that doesn’t work across the board, then maybe look into using IntentLauncher where you need to.

1 Like

Don’t have too many devices but within Expo Go, I’ve tried on Android’s API 22, 27, and 30 and your suggestion works so far.

But I think I am seeing same issue with expo-store-review
I am doing something like this now and I don’t see it working on Android neither (it’s not opening the Play Store anymore):

            const available = await StoreReview.isAvailableAsync();
            if (available) {
                StoreReview.requestReview();
            }      

Don’t think I found anything in the changelog there…

StoreReview.requestReview() worked for me when I tested it now, but only the first time. Not sure if that’s to prevent an app from spamming the user.

What is available when you run the above code?

Good point. I actually am not sure since the code just skips over if it’s not available (plus this was on the standalone build not in Expo). So maybe that was it. But on iOS it worked so I was assuming an Android issue. The modal that shows this is set far apart enough (60 days) to make sure the review is available, but I actually am not sure what the rule for Android is… iOS I think allows you to ask for review again and again and 60 days should be plenty.
I did see this on Play store guidelines: If the app already has been reviewed by a user, they won't be prompted to review the app again. So kinda interesting there… How would I know if there is a review so I don’t ask for one again? :thinking: