-
-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add stub service worker so users can install on desktop with Chrome #11774
Conversation
So the sw.js is just a stub file, it needs a fetch event listener or chrome will not consider it installable. We could of course actually cache all the static assets, it would have a far bigger impact on performance than any of the reducing bundle size type optimisations, however that seemed like a lot of work given that its been mentioned riot may not always support the web (#11646 (comment)) At the least this makes it installable and adding the actual caching could be done as a follow up |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
676717b
to
c154a79
Compare
c154a79
to
8dc7098
Compare
@daleharvey , @jryans will be taking this one on. |
dismissing because it's not really relevant
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the contribution @daleharvey! I think this looks good technically, and we're going to give this a try in an experimental capacity, under the assumption that installable PWAs should just work the same as the regular web app.
As one last step, could add your sign off to the PR as described in CONTRIBUTING.rst? Once you've done that, we should be ready to merge. You can just add a comment with the sign off line if you like.
Just to clarify for others, Riot is committed to supporting both web and desktop for the long term. See #11646 (comment) for more detail. |
Signed-off-by: Dale Harvey <dale@arandomurl.com>
8dc7098
to
a41484c
Compare
Awesome thanks, I added the |
Thanks for working on this! 😁 It should show up on https://riot.im/develop in a few minutes and in the next release in a few weeks. |
As discussed in #11646
Fixes #11646