Quantcast
Channel: Active questions tagged react-native+ios - Stack Overflow
Viewing all articles
Browse latest Browse all 16552

Expo: Does App Store also required to have property key when asking notifications permissions in able approve?

$
0
0

My app got rejected when I submit my app. This is my first time to upload an IOS app to app store. I saw a lot of having a same issue like happened to me. My app are requesting some permissions to the user without clarifying the purpose.

So as they told I have to add this to my info.plist.

"infoPlist": {"NSLocationAlwaysAndWhenInUseUsageDescription": "","NSLocationWhenInUseUsageDescription": ","NSLocationUsageDescription": "","NSCameraUsageDescription": "","NSPhotoLibraryUsageDescription" :""      }

But I also have an asking permission for push notification function. And I can't find if this is also required to have some steps in able to approve or no.

export async function askForNotificationsPermission() {  const { status: existingStatus } = await Permissions.getAsync(Permissions.NOTIFICATIONS);  let finalStatus = existingStatus;  // only ask if permissions have not already been determined, because  // iOS won't necessarily prompt the user a second time.  if (existingStatus !== "granted") {    // Android remote notification permissions are granted during the app    // install, so this will only ask on iOS    const { status } = await Permissions.askAsync(Permissions.NOTIFICATIONS);    finalStatus = status;  }  // Stop here if the user did not grant permissions  if (finalStatus !== "granted") {    return null;  }  // Get the token that uniquely identifies this device  let token = await Notifications.getExpoPushTokenAsync();  return token;}

Viewing all articles
Browse latest Browse all 16552

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>