Fix: les PDF de règles ne se chargeaient plus dans la PWA
Build and Publish Docker Image / build-and-push-image (push) Successful in 1m45s
Build and Publish Docker Image / build-and-push-image (push) Successful in 1m45s
Ouvrir un PDF est une navigation : le repli SPA du service worker (navigateFallback) répondait index.html à la place du fichier. Les assets de jeux sont désormais exclus du repli. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
+4
-2
@@ -61,8 +61,10 @@ export default defineConfig({
|
||||
},
|
||||
],
|
||||
navigateFallback: "/index.html",
|
||||
// Never let the SPA fallback swallow API calls.
|
||||
navigateFallbackDenylist: [/^\/api/],
|
||||
// Never let the SPA fallback swallow API calls, nor game assets:
|
||||
// opening a rules PDF is a navigation, which would otherwise be
|
||||
// answered with index.html instead of the file.
|
||||
navigateFallbackDenylist: [/^\/api/, /^\/games-assets\//],
|
||||
cleanupOutdatedCaches: true,
|
||||
},
|
||||
}),
|
||||
|
||||
Reference in New Issue
Block a user