(And also, I've observed that webapps that notice they're on an iOS device can insist on being "added to the home screen" before they'll do anything, and so ensure their data stays around.)
The problematic aspect of this, is that there's no equivalent of this "exemption by user explicitly expressing the desire to keep the app around" for non-mobile Safari.
Maybe for desktop Safari, the data should be kept around if the web app's rel="canonical" URL is bookmarked in the browser?
Or desktop Safari could just support regular Progressive Web App standards, and so show an "Install App" indicator (like e.g. desktop Chrome does for this webapp: https://www.soundslice.com/). But I have a feeling Apple will never support this on desktop...
Unfortunately, the term has been co-opted to mean "website I can install/pin as an app". Again, Google is probably to blame for this, but AFAICT it was never meant to be the meaning of the term. What it does do is create misunderstandings, like a sibling thread claiming that (desktop) Firefox doesn't support PWAs because you can't install anything.
[1] https://developer.mozilla.org/en-US/docs/Web/Progressive_web...
And "progressive enhancement" just means "being written in such a way that you'll work with a core set of APIs — all the way down to 'no javascript support' — but will take advantage of further APIs if they're available." Where the app forms a sort of Russian nesting doll of functionality, where it "launches" with just the innermost layer (e.g. just server-rendered HTML), and then in turn each new layer is enabled if possible (i.e. if Javascript is enabled, the browser will load some JS from a <script> tag that will then take over the DOM and turns the page into a SPA; etc.)
It's just a further refinement of the older concept of "graceful degradation", where the gracefully-degraded experience is delivered at the start, and then bootstrapped out into the non-degraded version.
Under this definition, the "further layers of functionality" provided to "installed" webapps in some browsers are just a specific kind of progressive enhancement. The app detects that it's being run "installed", and takes advantage of that. (And before that, the browser detects that the app has such a layer, and therefore treats the webapp as "installable.")
Thus, all "installable" apps are PWAs. (But not all PWAs are "installable"!)
I would note that webapps like Slack — i.e. webapps that have both web and "native" versions, where the "native" version is just the same remote webapp from the web version, loaded in a special browser that exposes extra capabilities that the webapp then takes advantage of — are also PWAs by this definition.
Edit: In order for this to be true, Apple (at the very least) needs to enable push notifications and an install prompt for progressive web apps.
Although I agree that it's a fairly minor win in the grand scheme of how handicapped PWA's are on iOS. And like you said, the lack of install prompts and tucking away the PWA "installation" option in the share menu makes it less than intuitive and requires manual awareness efforts by devs[2].
[1] Last section of https://webkit.org/tracking-prevention/
> It’s important to ensure that our iOS visitor is using Safari because iOS doesn’t permit other browsers to install our awesome PWA’s!
So if the user is using Firefox or Chrome etc browser, they can’t do it. And since all browsers have to use WKWebView, the limitation applies to all browsers. Apple has basically crippled other browsers with this anti competitive behaviour.
Like wish granted! You can now use Blink and V8 on iPhones! But…
* They still are required to delete website data after 7 days.
* They must distribute add-ones through the App Store.
* They still can’t run workers in the background because the browser is slept like any other app.
* They have to use Apple’s notification service like any other app.
* They can’t install things to the Home Screen because no other app can.
But yayyyy. Blink!
I don't think this web app is going to do as well on Apple devices because of the lack of notifications and also the difficulty to add to home screen.
BTW, you have to give the web app permission to notify. It's not like native apps.
Apple has clearly crippled PWAs to maintain their walled garden.
This makes total sense to me, and I’m happy Facebook can’t store tracking data in my Safari for longer than 7 days.
And the majority of uses for local data is to cache fetched data or store temporary preferences not worthy of being in the server side database.
They’re storing it somewhere, no? I feel like the benefit here is more so the browser file system doesn’t get bloated
Can you run a PWA on an iPhone? Yes, you can even pin them to the start screen to keep data long term, as others have pointed out.
Are you able to use all features other browsers enable? No, only the ones Apple allows.
Nevermind that there's nothing strictly stopping GM from changing the designs for Buicks to include a vehicle capable of a fifth wheel mount.
Also in my opinion websites have no business storing data on my device through a browser. If I want that behavior I would use a native app.
We will provide a new backend for the Storage Foundation API when it's available.
As a bonus point this effectively adds yet another level of "Yo, Dawg" which I can't not love just as a matter of principle.
Oddly enough the handful of web apps I’ve known to use local storage don’t communicate this at all. Developers seemingly treat data in browser local storage as existing indefinitely and unlikely to be deleted, when in fact it’s probably the most easily accidentally lost form of storage an app can have.
If, on the other hand, you're explicitly uploading or entering data on a web site, well then yes, the default assumption would certainly be that the data is getting saved on the web site's servers (if it's being saved at all). That's how the web has worked for a very long time, with the exception of cookies and a few other more recent but not widely known storage mechanisms which in most cases aren't considered sufficiently robust for persistent on-device storage.
Webkit says in your source:
> It is not the intention of Intelligent Tracking Prevention to delete website data for first parties in web applications.
Safari will happily delete your IndexedDB database after 7 days of inactivity.
It deletes "all of a website’s script-writable storage after seven days of Safari use without user interaction on the site". That includes:
- Indexed DB
- LocalStorage
- Media keys
- SessionStorage
- Service Worker registrations and cache
Source: https://webkit.org/blog/10218/full-third-party-cookie-blocki...
Found via: The pain and anguish of using IndexedDB: problems, bugs and oddities - https://gist.github.com/pesterhazy/4de96193af89a6dd5ce682ce2...