mo 1 tahun lalu
induk
melakukan
8fa38b8bf5
1 mengubah file dengan 14 tambahan dan 0 penghapusan
  1. 14 0
      vite.config.ts

+ 14 - 0
vite.config.ts

@@ -70,6 +70,20 @@ export default defineConfig({
             options: {
               cacheName: 'js-css-cache'
             }
+          },
+          {
+            urlPattern: /.*\.html.*/,
+            handler: 'NetworkOnly',
+            options: {
+              cacheName: 'wisbayar-html',
+              expiration: {
+                maxEntries: 20,
+                maxAgeSeconds: 30 * 24 * 60 * 60
+              },
+              cacheableResponse: {
+                statuses: [200]
+              }
+            }
           }
         ]
       },