Hacker News new | ask | show | jobs
by jauntywundrkind 1070 days ago
> We've removed the service worker functionality as it didn't bring any noticeable benefit, mostly added bugs, and was disabled since 1.17 by default already.

Anyone have any info on what this was alleged to help with? Sad to see a regression like this. There should be great potential here.

2 comments

The comment for the option in the Gitea config file says that service workers were used to cache frontend assets.

However, the PR that disabled it by default noted that enabling service workers caused JS errors after Gitea instance upgrades. The PR also noted that service workers didn't provide any benefit over regular HTTP caching.

Service workers are great. Quite strange how they would remove it. It would dramatically speed up the site for any slow hosts.
A browser's HTTP cache works similar to a service worker cache, except that there are clear ways to invalidate via headers, while the APIs to invalidate the service worker cache are obscure and stale cache had caused multiple issues in the past.

I agree that SW can work if you write your UI around them, but Gitea isn't really such an UI.