Skip to content

Commit ea040a7

Browse files
committed
main
1 parent 70bec75 commit ea040a7

2 files changed

Lines changed: 10 additions & 0 deletions

File tree

.github/workflows/main.yml

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,12 @@ jobs:
1313
run: npm install
1414
- name: 打包
1515
run: npm run build
16+
- name: 產生 SPA fallback 與網域設定
17+
run: |
18+
cp dist/index.html dist/404.html
19+
if [ -f CNAME ]; then
20+
cp CNAME dist/CNAME
21+
fi
1622
- name: 發布分支 Web-Page
1723
uses: JamesIves/github-pages-deploy-action@v4
1824
with:

src/router/index.js

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,10 @@ const router = createRouter({
2121
name: 'privacy',
2222
component: PrivacyView,
2323
},
24+
{
25+
path: '/:pathMatch(.*)*',
26+
redirect: '/',
27+
},
2428
],
2529
})
2630

0 commit comments

Comments
 (0)