feat: 初始化项目

This commit is contained in:
Daniel
2026-03-07 19:37:38 +08:00
parent ea760bb71c
commit 382aa955ef
13 changed files with 447 additions and 166 deletions

10
server/index.js Normal file
View File

@@ -0,0 +1,10 @@
#!/usr/bin/env node
/**
* 单独启动后端 API仅 API 路由,不提供静态资源)。
* 用于前后端分离部署时,将本目录部署到 Node 主机。
*/
const app = require('./server.js');
const PORT = process.env.PORT || 3000;
app.listen(PORT, () => {
console.log('API 已启动: http://localhost:' + PORT);
});