From 1da7a73f89b50e17387344efa889d3b74e7af7f4 Mon Sep 17 00:00:00 2001 From: CHOYSEN Date: Sat, 14 Aug 2021 17:58:19 +0800 Subject: [PATCH] chore: add comment --- src/client/app/index.ts | 1 + 1 file changed, 1 insertion(+) diff --git a/src/client/app/index.ts b/src/client/app/index.ts index cdb79a35..29b66e77 100644 --- a/src/client/app/index.ts +++ b/src/client/app/index.ts @@ -117,6 +117,7 @@ function newRouter(): Router { isInitialPageLoad = false const page = import(/*@vite-ignore*/ pageFilePath) + // fallback to base url when visit a non-exist page at first page.catch(() => (location.href = import.meta.env.BASE_URL)) return page }