feat(pwa): implement PWA installation banner and context provider
- Add `generate-icons.ts` script to generate PWA icons from SVG. - Create `InstallBanner` component for prompting users to install the app. - Implement `PwaProvider` to manage PWA installation state and events. - Export `PwaProvider` and `InstallBanner` from the PWA feature index.
This commit is contained in:
@@ -40,6 +40,14 @@ server {
|
||||
try_files $uri =404;
|
||||
}
|
||||
|
||||
# ── Service worker y manifest ─────────────────────────────────────────────
|
||||
# Nunca se cachean: el navegador tiene que ver la versión nueva en el próximo
|
||||
# load. `=404` y no el fallback del SPA, porque un 404 del SW debe ser un 404.
|
||||
location ~ ^/(sw\.js|workbox-[^/]+\.js|manifest\.webmanifest)$ {
|
||||
add_header Cache-Control "no-cache";
|
||||
try_files $uri =404;
|
||||
}
|
||||
|
||||
# ── SPA ────────────────────────────────────────────────────────────────────
|
||||
location = /index.html {
|
||||
add_header Cache-Control "no-cache";
|
||||
|
||||
Reference in New Issue
Block a user