1
1
mirror of https://github.com/go-gitea/gitea synced 2024-11-08 19:24:25 +00:00
gitea/modules/templates
silverwind 655def5141
Move serviceworker to workbox and fix SSE interference (#11538) (#11547)
* Move serviceworker to workbox and fix SSE interference

Instead of statically hardcoding every frontend asset, this uses a
type-based approach to cache all js,css and manifest.json requests.

This also fixes the issue that the service worker was interfering with
EventSource because it was unconditionally handling all requests which
this new implementation doesn't.

Fixes: https://github.com/go-gitea/gitea/issues/11092
Fixes: https://github.com/go-gitea/gitea/issues/7372

* rethrow error instead of logging

* await .register

* Revert "rethrow error instead of logging"

This reverts commit 043162ba1f.

* improve comment

* remove JSRenderer

* add version-based cache invalidation

* refactor

* more refactor

* remove comment

* rename item to fit cache name

Co-authored-by: guillep2k <18600385+guillep2k@users.noreply.github.com>
2020-05-22 12:46:39 -03:00
..
dynamic.go Move serviceworker to workbox and fix SSE interference (#11538) (#11547) 2020-05-22 12:46:39 -03:00
helper_test.go Use templates for issue e-mail subject and body (#8329) 2019-11-07 21:34:28 +08:00
helper.go Add EventSource support (#11235) 2020-05-07 22:49:00 +01:00
static.go Move serviceworker to workbox and fix SSE interference (#11538) (#11547) 2020-05-22 12:46:39 -03:00
templates_bindata.go Rename scripts to build and add revive command as a new build tool command (#10942) 2020-04-03 22:29:12 +03:00