From f7b588ce3c66fb5664f8876272284ef10690efbf Mon Sep 17 00:00:00 2001 From: xream Date: Mon, 29 Jan 2024 12:31:47 +0800 Subject: [PATCH] =?UTF-8?q?revert:=20=E5=9B=9E=E9=80=80=20workbox=20?= =?UTF-8?q?=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package.json | 2 +- vite.config.ts | 6 ++---- 2 files changed, 3 insertions(+), 5 deletions(-) diff --git a/package.json b/package.json index 643eca10a..9acd1cb65 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "sub-store-front-end", - "version": "2.14.117", + "version": "2.14.118", "private": true, "scripts": { "dev": "vite --host", diff --git a/vite.config.ts b/vite.config.ts index 13df092f4..264c2b5b8 100644 --- a/vite.config.ts +++ b/vite.config.ts @@ -92,11 +92,9 @@ const viteConfig = defineConfig((mode: ConfigEnv) => { ], }, workbox: { + navigateFallbackDenylist: [/(^|\/.+)\/(api|download)\/.+/], + // globPatterns: ['**/*.{css,js,gz,eot,html,svg,png,ico,ttf,woff2}'], runtimeCaching: [ - { - urlPattern: /^https?:\/\/.+?\/(?:api|download)\/.+/, - handler: "NetworkOnly", - }, { urlPattern: /.*\.(?:js|css|gz|html|json)/i, // json handler: 'CacheFirst',