-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Disable/enable notification #485
Comments
any news on this? I would love to disable when the user log out and reenable them when log in |
yes it is possible now on this commit of our forked repo : surialabs@39d7adb For Android & iOS
|
abandonePermissions method don't block the remote notification on Android. What should I do to block the remote notification in a specific page? |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 30 days if no further activity occurs. Thank you for your contributions. |
@github-actions Don't close. |
From README: Abandon Permissions PushNotification.abandonPermissions() Revokes the current token and unregister for all remote notifications received via APNS or FCM. |
As @danielsgit said. It seems It shows duplicate notifications on my device. (I use local notification.) |
Yeah, this was true last year |
Abandoning and then re-registering for notifications is a truly hacky workaround to being able to intercept push notifications before they are displayed on the device. There ought to be a handler which fires before a notification ever reaches the device, and allows for re-routing (or simply not displaying) that particular notification. Any chance we can get this going? |
I also need this. How do we manage notifications by having a way to disable and re-enable? I was following the doc and tried cancelLocalNotification but got _reactnativepushnotification.default.cancellocalnotification is not a function |
@jimzqw did you find any solution for your question? Because I am also stuck on this problem. I opened an issue about this but they deleted my issue. It is really funny and annoying |
is there any update ? |
This still is an issue. |
My solution for now is unsub and resub based on your needs. Like if I don't want users to get notification on a certain page I will unsubscribe user, and resubscribe when they exit that page. |
Is it possible to disable and enable notification?
The text was updated successfully, but these errors were encountered: