New logic to detect PWA offline support

preview_player
Показать описание

This new logic is not available yet. Chrome will run experiments to see how many websites are affected and make sure that the new logic will not cause an unacceptable delay to the page loading time. Chrome will ship the feature after sufficient announcements have been made.

Resources:

Speaker: Asami Doi

#chromedevsummit #chrome #pwa

event: Chrome Dev Summit 2020; re_ty: Publish; product: Chrome - General; fullname: Asami Doi;
Рекомендации по теме
Комментарии
Автор

Now pls implement periodic-background-sync, so I can update badges without sending a whole Notification thing, respect user attention

jerrygreenest
Автор

ServiceWorker is a proxy and therefore should not limit installability to "200" status responses only. Many logics can return a different status and therefore a random test based (or not) on euristicas that arrives at a different status code would prevent the installability. Some examples:

Using routes to manage a CRUD IndexedDB ... status code "201" or any other applicable such as "409", "429" would cause rejection.

Offline authentication methods (for decrypting content, for example) "401" (or 407) would cause rejection. Here "403" would also cause rejection.

There are so many other possibilities of logic on the ServiceWorker side that it would not fit in this comment ... the "magic" of a ServiceWorker is not restricted to the "GET" method nor to a "200" status response.

lauromoraes
Автор

Nice, PWA is really great but offline cache seems to disappear after a day. I get the offline dinosaur eventhough the cache system seems to work after the first connexion of the day. Thanks for the work Asami.

Автор

Just thinking out loud, can this work like a Chrome plug-in? Will this allow me to extend the session storage/ create custom local storage to save, say, client projects, cache, etc?

tejaschavan
Автор

i just want chrome to be able to read aloud

demiegun
Автор

What about apps that just display a "connect to the internet" message? Will those eventually be detected?

hedgehog
Автор

thank you, very..very much.. for this tutorial :)

hadifox
Автор

location.reload() is not working in offline for pwa

jaibunnisamohammad
Автор

My pwa works offline but your new checks say it doesn’t. So don’t be telling people if their app works offline it will be installable. Your new logic is no more accurate than your old logic and it also prohibits pwas that work offline from installing. I’m glad you’re excited to screw people over that have made apps that work offline. And by the way, a large percentage of native apps do not work offline.

oso
Автор

While I am thoroughly in support of diverse and fair hiring practices. Why do you not field a person who speaks a more understandable English accent? You can use this person for making the video in their native language, but as a commonplace english speaker (US/UK) it makes it very very hard to follow.

chinmayk
Автор

*De un tiempo a ésta parte la extensión de comentario ha tomado valor objetivo ya q no importaba mucho, pero q encontraba manera de participar de los problemas de manera pro activa ... Nos deben dinero por prestarse a mentir y mentir y ofender sugiriendo q somos tontos ... Saludos ✋⚡✒*

pabloleganttineoantelo
Автор

*Lo malo es jugarse al más inteligente por encima de los pueblos q no son nada tontos y q ya están determinados a hacer justicia, cobrar y dar lección de vida ... Saludos ✋⚡✒*

pabloleganttineoantelo