Fix SPA routing for GitHub Pages deployment
- Update 404.html with React content instead of Vue - Add automatic 404.html copy to build script - Fix URL typo in og:url meta tag - Ensure client-side routing works for user pages 🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <noreply@anthropic.com>
This commit is contained in:
		| @@ -19,7 +19,8 @@ | |||||||
|       "Bash(find:*)", |       "Bash(find:*)", | ||||||
|       "Bash(rm:*)", |       "Bash(rm:*)", | ||||||
|       "Bash(grep:*)", |       "Bash(grep:*)", | ||||||
|       "Bash(ls:*)" |       "Bash(ls:*)", | ||||||
|  |       "Bash(cp:*)" | ||||||
|     ], |     ], | ||||||
|     "deny": [] |     "deny": [] | ||||||
|   } |   } | ||||||
|   | |||||||
| @@ -5,7 +5,7 @@ | |||||||
|   "type": "module", |   "type": "module", | ||||||
|   "scripts": { |   "scripts": { | ||||||
|     "dev": "vite", |     "dev": "vite", | ||||||
|     "build": "tsc && vite build", |     "build": "tsc && vite build && cp dist/index.html dist/404.html", | ||||||
|     "preview": "vite preview", |     "preview": "vite preview", | ||||||
|     "lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0" |     "lint": "eslint . --ext ts,tsx --report-unused-disable-directives --max-warnings 0" | ||||||
|   }, |   }, | ||||||
|   | |||||||
| @@ -1,12 +1,21 @@ | |||||||
| <!DOCTYPE html> | <!DOCTYPE html> | ||||||
| <html lang="en"> | <html lang="ja"> | ||||||
| <head> | <head> | ||||||
| 		<meta charset="utf-8"><meta http-equiv="X-UA-Compatible" content="IE=edge"><meta name="viewport" content="width=device-width,initial-scale=1"><title>card.syui.ai</title><link href="app.css" rel="preload" as="style"><link href="app.js" rel="preload" as="script"><link href="chunk-vendors.js" rel="preload" as="script"><link href="app.css" rel="stylesheet"> |     <meta charset="UTF-8" /> | ||||||
|  |     <link rel="icon" type="image/svg+xml" href="/ai.svg" /> | ||||||
|  |     <meta name="viewport" content="width=device-width, initial-scale=1.0" /> | ||||||
|  |     <title>card.syui.ai</title> | ||||||
|  |     <link rel="stylesheet" href="/pkg/icomoon/style.css" /> | ||||||
|  |     <link rel="stylesheet" href="/pkg/font-awesome/css/all.min.css" /> | ||||||
|  |     <script type="module" crossorigin src="/index.js"></script> | ||||||
|  |     <link rel="stylesheet" crossorigin href="/index.css"> | ||||||
|     <meta name="twitter:card" content="summary"> |     <meta name="twitter:card" content="summary"> | ||||||
| 		<meta property="og:url" content="https://card.syui.aiL"> |     <meta property="og:url" content="https://card.syui.ai"> | ||||||
|     <meta property="og:title" content="card.syui.ai"> |     <meta property="og:title" content="card.syui.ai"> | ||||||
|     <meta property="og:description" content="@yui.bsky.social /card"> |     <meta property="og:description" content="@yui.bsky.social /card"> | ||||||
|     <meta property="og:image" content="https://card.syui.ai/card/card_0.png"> |     <meta property="og:image" content="https://card.syui.ai/card/card_0.png"> | ||||||
| </head> | </head> | ||||||
| 	<body><div id="app"></div><script src="chunk-vendors.js"></script><script src="app.js"></script></body> | <body> | ||||||
|  |     <div id="root"></div> | ||||||
|  | </body> | ||||||
| </html> | </html> | ||||||
|   | |||||||
		Reference in New Issue
	
	Block a user