We are building a progressive web app for iOS devices and we know about the 50 MiB cache limitation imposed by the Safari web browser. How can we handle this limitation when we know that our app's service worker might have to cache data more than 50 MiB if we include all the static resources, videos and pictures etc. Our first preference is to keep the app running offline even after the cache is full and if that is not possible than at least prevent the app from breaking if the user is working offline.
It would be good if you give a generic answer which we can implement in other PWAs also.
Every major browser and platform has support for service workers and are using the web manifest file in some form or fashion. This includes Apple's iPhones and iPads using iOS Safari. Do Progressive Web Apps (PWA) work on iOS? YES!!!
The group limit — this is defined as 20% of the global limit, but it has a minimum of 10 MB and a maximum of 2 GB. Each origin is part of a group (group of origins).
These days you can store much more than 50 MB on Safari mobile using IndexedDB: https://love2dev.com/blog/what-is-the-service-worker-cache-storage-limit/
If the size of free disk space is over 1 GB, the default limit is 500 MB; otherwise it is half the free disk space.
See for yourself using this tool: https://demo.agektmr.com/storage/
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With