From 3b96b42d4bed2ba0f41e3c1dcff7387653b641d9 Mon Sep 17 00:00:00 2001 From: grassblock Date: Sun, 18 May 2025 16:48:51 +0800 Subject: [PATCH] chore(static web apps): fix 404 page --- staticwebapp.config.json | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 staticwebapp.config.json diff --git a/staticwebapp.config.json b/staticwebapp.config.json new file mode 100644 index 0000000..c56f2f2 --- /dev/null +++ b/staticwebapp.config.json @@ -0,0 +1,19 @@ +{ + "trailingSlash": "auto", + "routes": [ + { + "route": "/*", + "headers": { + "cache-control": "must-revalidate, max-age=15770000" + } + } + ], + "responseOverrides": { + "404": { + "rewrite": "/404.html" + } + }, + "globalHeaders": { + "content-security-policy": "default-src https: 'unsafe-eval' 'unsafe-inline'; object-src 'none'" + } +} \ No newline at end of file