chore: add ignore widget path in service worker

This commit is contained in:
Tristan Yang
2023-02-22 21:00:01 +08:00
parent b2ddd52f26
commit 0d315aa0a6
3 changed files with 159 additions and 67 deletions
+2 -2
View File
@@ -33,8 +33,8 @@ registerRoute(
return false;
} // If this is a URL that starts with /_, skip.
const urlPath = url.pathname;
// 忽略swagger文档 本地语言文件
if (urlPath.startsWith("/api/swagger") || urlPath.startsWith("/locales/")) {
// 忽略swagger文档 本地语言文件 挂件地址
if (urlPath.startsWith("/api/swagger") || urlPath.startsWith("/locales/") || urlPath.startsWith("/widget")) {
return false;
}
if (urlPath.startsWith("/_")) {