mirror of
https://github.com/phranck/TUIkit.git
synced 2026-05-21 09:50:35 +00:00
Chore: Add GitHub Pages routing support for DocC
- Copy index.html as 404.html for SPA deep-link routing - Replace root index.html with redirect to /documentation/tuikit/
This commit is contained in:
@@ -125,6 +125,26 @@ jobs:
|
||||
--output-path docc-output \
|
||||
--transform-for-static-hosting
|
||||
|
||||
- name: Add routing support for GitHub Pages
|
||||
run: |
|
||||
# 404.html = copy of SPA index so all deep-link paths route through DocC
|
||||
cp docc-output/index.html docc-output/404.html
|
||||
# Root redirect: docs.tuikit.dev/ -> docs.tuikit.dev/documentation/tuikit/
|
||||
cat > docc-output/index.html << 'REDIRECT'
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="refresh" content="0; url=/documentation/tuikit/">
|
||||
<link rel="canonical" href="/documentation/tuikit/">
|
||||
<title>Redirecting to TUIkit Documentation</title>
|
||||
</head>
|
||||
<body>
|
||||
<p>Redirecting to <a href="/documentation/tuikit/">TUIkit Documentation</a>...</p>
|
||||
</body>
|
||||
</html>
|
||||
REDIRECT
|
||||
|
||||
- name: Deploy to tuikit-docs
|
||||
uses: peaceiris/actions-gh-pages@v4
|
||||
with:
|
||||
|
||||
Reference in New Issue
Block a user