mirror of
https://github.com/alam00000/bentopdf.git
synced 2026-11-07 16:41:00 +01:00
fixed routing
This commit is contained in:
+1
-1
@@ -109,7 +109,7 @@ self.addEventListener('fetch', (event) => {
|
||||
isLocal &&
|
||||
(url.pathname.endsWith('.html') ||
|
||||
url.pathname === '/' ||
|
||||
/^\/(en|fr|es|de|zh|zh-TW|vi|tr|id|it|pt|ru|nl|be)(\/|$)/.test(
|
||||
/^\/(en|ar|be|da|de|es|fr|id|it|ja|ko|nl|pl|pt|ru|sk|sv|tr|uk|vi|zh|zh-TW)(\/|$)/.test(
|
||||
url.pathname
|
||||
))
|
||||
) {
|
||||
|
||||
-10
@@ -22,16 +22,6 @@
|
||||
]
|
||||
}
|
||||
],
|
||||
"rewrites": [
|
||||
{
|
||||
"source": "/{lang}/**",
|
||||
"destination": "/{lang}/index.html"
|
||||
},
|
||||
{
|
||||
"source": "**",
|
||||
"destination": "/index.html"
|
||||
}
|
||||
],
|
||||
"cleanUrls": true,
|
||||
"trailingSlash": false
|
||||
}
|
||||
|
||||
+1
-2
@@ -91,7 +91,6 @@
|
||||
"permanent": true
|
||||
}
|
||||
],
|
||||
"rewrites": [{ "source": "/docs/:path*", "destination": "/docs/index" }],
|
||||
"headers": [
|
||||
{
|
||||
"source": "/(.*)",
|
||||
@@ -165,7 +164,7 @@
|
||||
]
|
||||
},
|
||||
{
|
||||
"source": "/docs/(.*)",
|
||||
"source": "/docs/:path*",
|
||||
"headers": [
|
||||
{
|
||||
"key": "Content-Security-Policy",
|
||||
|
||||
Reference in New Issue
Block a user