refactor: 推翻舊架構, 進入 Vite 盛世!

* 所有的 CDN 依賴已全部 npm 化
* Webpack? 一邊去! Vite 太好用啦!
* 將 Imports.ts 剔除
* 移除了大量的靜態文件
* 將 index.html 的部分代碼分離
* 修改 deno task
* 移除了動態編譯頁面的支持
* ./static 引用全部變更為 npm 包引用
This commit is contained in:
CrescentLeaf
2025-09-07 12:49:09 +08:00
parent b6140063c7
commit 25320fe521
74 changed files with 217 additions and 36326 deletions

View File

@@ -1,18 +1,12 @@
{
"tasks": {
"main": "deno run --allow-read --allow-write --allow-env --allow-net --allow-sys ./server/main.ts",
"debug": "deno run --watch --allow-read --allow-write --allow-env --allow-net --allow-sys ./server/main.ts",
"test": "deno run --allow-read --allow-write --allow-env --allow-net ./server/main_test.ts"
"server": "deno task build && deno run --allow-read --allow-write --allow-env --allow-net --allow-sys ./server/main.ts",
"build": "cd ./client && deno task build"
},
"imports": {
"chalk": "npm:chalk@5.4.1",
"file-type": "npm:file-type@21.0.0",
"express": "npm:express@5.1.0",
"socket.io": "npm:socket.io@4.8.1",
"@babel/core": "npm:@babel/core@^7.26.10",
"@babel/preset-env": "npm:@babel/preset-env@7.26.9",
"@babel/preset-react": "npm:@babel/preset-react@7.26.3",
"@babel/preset-typescript": "npm:@babel/preset-typescript@7.27.1"
"socket.io": "npm:socket.io@4.8.1"
}
}