gauntface / simple-push-demo

A simple example of use push notifications on the web using Service Workers
https://simple-push-demo.vercel.app/
Apache License 2.0
890 stars 217 forks source link

Testing on iOS 16.4 ( Safari, Firefox. Chrome) #321

Open gedw99 opened 1 year ago

gedw99 commented 1 year ago

Apple have enabled it đź‘Ť

https://techcrunch.com/2023/03/27/apple-releases-ios-16-4-with-new-emojis-web-push-notifications-voice-isolation-for-calls-more/amp/

when I try from my iOS device, the web page’s “enable push notifications “ switch is not enabled.

First clock “share” and “ add to Home Screen”.

IMG_1689

then you can add it:

IMG_1690

gedw99 commented 1 year ago

got to be on iOS 16.4

IMG_1687

gauntface commented 1 year ago

I'll have to give this a try and update the UI as necessary.

We have the comment added by @FluorescentHallucinogen but it might not adopting if it's being overlooked (I really don't want to have to special case safari though).

I also need to improve the A2HS icon.

gedw99 commented 1 year ago

I got it to work and updated the issue with screen shots to help.

thanks for quick response .

gedw99 commented 1 year ago

Firefox and chrome on iOS don’t seem to work.

when I use the Share button for them I don’t se the “Add to Home Screen “ Action in the list ..

gedw99 commented 1 year ago

Firefox team says it should work:

https://github.com/mozilla-mobile/firefox-ios/discussions/13281

I raised an issue there …

FluorescentHallucinogen commented 1 year ago

@gedw99

Adding web apps to home screen has been implemented in Chrome for iOS (see https://crbug.com/1418932 and https://crrev.com/c/4271192). :wink:

Could you please check if Chrome Beta 112+ is available in TestFlight?

FluorescentHallucinogen commented 1 year ago

@gedw99

Firefox team says it should work

They say exactly the opposite. :) See https://github.com/mozilla-mobile/firefox-ios/discussions/13281#discussioncomment-5470521.

cycchow commented 1 year ago

i did test the demo in physical iphone, which work in 16.4, however i have no idea why the service worker can't be register in the ios16.4 simulator

FluorescentHallucinogen commented 1 year ago

@cycchow

service worker can't be register in the ios16.4 simulator

Are you sure that the problem is with the service worker registration?

As far as I know, the iOS simulator simply doesn't support push notifications, even for native apps.