From 3424f9a952cffe64e1426a5449cc88276c1533f6 Mon Sep 17 00:00:00 2001 From: Spythere Date: Mon, 15 Apr 2024 16:36:30 +0200 Subject: [PATCH] chore(pwa): image caching changes --- vite.config.ts | 18 +----------------- 1 file changed, 1 insertion(+), 17 deletions(-) diff --git a/vite.config.ts b/vite.config.ts index e2f87a8..b73537e 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -38,28 +38,12 @@ export default defineConfig({ }, }, }, - { - urlPattern: new RegExp('^https://static.spythere.eu/images/*', 'i'), - handler: 'CacheFirst', - options: { - cacheName: 'spythere-api-cache', - expiration: { - maxEntries: 100, - maxAgeSeconds: 60 * 60 * 24, // <== 1 day - }, - cacheableResponse: { - statuses: [200, 302], - }, - }, - }, + { urlPattern: new RegExp('^https://stacjownik.spythere.eu/vehicles', 'i'), handler: 'NetworkFirst', options: { cacheName: 'vehicles-cache', - cacheableResponse: { - statuses: [200], - }, }, }, ],