I am writing this blog to share my findings on a question that I had during the developments of PWA. I went through many blogs and tutorials for this and I found few things are not working with IOS while Android has good support for PWA.
Let's see them one by one.
Can PWA access camera?
Yes, both the OS gives access to the camera, which allows image and video capturing in PWA.
Android: YES
IOS: YES
Can PWA work offline?
PWA leverages data caching during your last interactions with the app, and by doing that it works offline while there is no internet connection.
Android: YES
IOS: YES
Can PWA access the file system?
is the only way you can access a regular storage file system, which will not have any event listener. PWA can't listen to regular file system changes except for the files of APP.
Can PWA access the Bluetooth?
The web Bluetooth API is a low-level API allowing web applications to pair with the nearby Bluetooth Low Energy-enabled peripheral devices and access their services exposed. But it's not supported on all platforms.
Android: YES
IOS: NO
Can PWA access the phone’s GPS?
A lot of browsers support this recent feature and these include Chrome, Edge, Firefox, Safari, and Opera. In IE, you’ll have to battle a few configurations to make it work
Android: YES
IOS: YES
Can PWA use advanced camera functionality?
Advanced camera functionality is not available on all platforms. For example QR CODE scanning.
Android: YES
IOS: NO
Can PWA access contacts?
No there is no way to access contacts in PWA, it is mainly restricted for security purposes.
Android: NO
IOS: NO
Can PWA check for new updates?
Yes, in order to achieve this you have to check your cached files are changed or not. We can implement this by writing a hook in onupdatefound function on the registered Service Worker.
Here I found a detailed blog for this that explained each step in detail.
https://medium.com/progressive-web-apps/pwa-create-a-new-update-available-notification-using-service-workers-18be9168d717
Can PWA have Push Notifications?
This is the most crucial part of any applications and many product owners avoid PWA just because of these limitations. Android support push notifications but IOS does not support. Maybe Apple can update in the next version 14. But we have to wait till that.
Android: YES
IOS: NO
Top comments (10)
Notifications are the biggest gripe right now. I wish LocalNotifications API just worked out of the box without any need for complicated Google services. they don't even seem to work on non-pwas on mobile.
Great article, it served well for almost 4 years but it might need an update though. Starting with push notifications, ios is claimed to be supporting web-push now.
developer.apple.com/documentation/...
qvik.com/news/web-push-notificatio...
This is a great site for demoing some of the PWA features.
whatpwacando.today/
Chrome 80+ support the Contact Picker API which can help you access the contact list of a smartphone 😉
web.dev/contact-picker/
Thanks for share, it will be very helpful to us.
Nice post !
Why not talking about the App Store support ? You can now publish PWA on Play Store (idk about Apple Store)
Thanks for read.
Will try to cover this topic in our future blogs.
Wow, great checklist.
Your words motivates us.
Thanks..
How Can PWA access the phone’s GPS? Please share any API or reference link for accessing GPS location via offline using PWA
How can we prevent PWA from refreshing?
I have created a PWA Chat App. The App refreshes the page after uploading a photo using a mobile Camera and also, reloads after switching between apps.