OneSignal / react-onesignal

React OneSignal Module: Make it easy to integrate OneSignal with your React App!
Other
74 stars 23 forks source link

Add isPushNotificationsSupported API #51

Closed slamacchia closed 1 year ago

slamacchia commented 2 years ago

Glad to hear OneSignal supporting this package!

Is it possible to add back the isPushNotificationsSupported() APi?:

Or is there another way of determining this now?

I find this feature useful for hiding web push notification settings in my web app on unsupported browsers (i.e. iOS Safari).

rgomezp commented 2 years ago

Howdy, Thanks for flagging this. We will discuss internally on adding this back in a future version.

Cheers

nynevi commented 2 years ago

I would also like this to be officially supported but just fyi window.OneSignal.isPushNotificationsSupported() works already though. not sure if there is a downside on using it.

rgomezp commented 2 years ago

Howdy, There is no downside to using it @nynevi

rgomezp commented 1 year ago

Closing since we have decided not to add to the existing API & there is a workaround (mentioned above).

In the upcoming major release, this will be included!

Enjoy!