Checking to see if pushNotification dialog has been shown?

#1

I have a custom screen that asks the users to enable push notification when they first register for the app.
Is there a way to check if the official push notification dialog has been shown [in iOS you can only answer the prompt once]

const { status } = await Permissions.askAsync(Permissions.NOTIFICATIONS)

I can check if the status is undetermined, the issue with that is that if someone turns off the push notifications in settings then the user see’s my custom dialog again.

can i instead check the token ?

await Notifications.getExpoPushTokenAsync()

i’m trying to avoid using local storage and just rely on the device

0 Likes

closed #2

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.

0 Likes