Implementar link handling y asociación con PWA hub
- Agregar capture_links en manifest para mejorar experiencia PWA - Crear archivo .well-known para asociación con inicio.nucleoriofrio.com - Configurar Traefik para servir .well-known sin autenticación
This commit is contained in:
@@ -24,7 +24,8 @@ services:
|
||||
- "traefik.http.services.${APP_NAME}.loadbalancer.server.port=3000"
|
||||
|
||||
# Router 1: Public PWA resources (no auth) - Higher priority
|
||||
- "traefik.http.routers.${APP_NAME}-public.rule=Host(`${APP_DOMAIN}`) && (PathPrefix(`/manifest.webmanifest`) || PathPrefix(`/sw.js`) || PathPrefix(`/workbox-`) || PathPrefix(`/icon-`) || PathPrefix(`/apple-touch-icon`) || PathPrefix(`/favicon.ico`) || PathPrefix(`/robots.txt`) || PathPrefix(`/offline.html`) || PathPrefix(`/api/_nuxt_icon/`))"
|
||||
# Incluye .well-known para scope extensions
|
||||
- "traefik.http.routers.${APP_NAME}-public.rule=Host(`${APP_DOMAIN}`) && (PathPrefix(`/.well-known`) || PathPrefix(`/manifest.webmanifest`) || PathPrefix(`/sw.js`) || PathPrefix(`/workbox-`) || PathPrefix(`/icon-`) || PathPrefix(`/apple-touch-icon`) || PathPrefix(`/favicon.ico`) || PathPrefix(`/robots.txt`) || PathPrefix(`/offline.html`) || PathPrefix(`/api/_nuxt_icon/`))"
|
||||
- "traefik.http.routers.${APP_NAME}-public.entrypoints=websecure"
|
||||
- "traefik.http.routers.${APP_NAME}-public.tls.certresolver=letsencrypt"
|
||||
- "traefik.http.routers.${APP_NAME}-public.priority=100"
|
||||
|
||||
@@ -34,6 +34,8 @@ export default defineNuxtConfig({
|
||||
orientation: 'portrait',
|
||||
scope: '/',
|
||||
start_url: '/',
|
||||
// Capturar enlaces dentro de la app
|
||||
capture_links: 'existing-client-navigate',
|
||||
icons: [
|
||||
{
|
||||
src: '/icon-192x192.png',
|
||||
|
||||
10
nuxt4/public/.well-known/web-app-origin-association
Normal file
10
nuxt4/public/.well-known/web-app-origin-association
Normal file
@@ -0,0 +1,10 @@
|
||||
{
|
||||
"web_apps": [
|
||||
{
|
||||
"manifest": "https://inicio.nucleoriofrio.com/manifest.webmanifest",
|
||||
"details": {
|
||||
"paths": ["/*"]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
Reference in New Issue
Block a user