lighthouse fixes
This commit is contained in:
@@ -46,3 +46,19 @@ The Service Worker SHALL use versioned caches and remove old caches during activ
|
||||
#### Scenario: Activate new version and clean old caches
|
||||
- **WHEN** a new service worker version activates
|
||||
- **THEN** it deletes caches from older versions and begins using the current versioned caches
|
||||
|
||||
### Requirement: Critical assets do not remain stale after deploy
|
||||
The service worker and server caching strategy MUST ensure critical shell assets (including the global stylesheet and service worker script) do not remain stale across deploys.
|
||||
|
||||
The implementation MUST include at least one cache-busting mechanism for critical assets, such as:
|
||||
|
||||
- content-hashed asset filenames, or
|
||||
- an asset version query suffix that changes per deploy
|
||||
|
||||
#### Scenario: New deploy updates critical CSS
|
||||
- **WHEN** a new deploy is released and a returning user loads the site
|
||||
- **THEN** the user receives the updated global stylesheet without requiring a manual hard refresh
|
||||
|
||||
#### Scenario: Service worker updates predictably
|
||||
- **WHEN** a new deploy is released
|
||||
- **THEN** the browser can retrieve the updated service worker script and activate it without being pinned by long-lived caches
|
||||
|
||||
Reference in New Issue
Block a user