继续提交

This commit is contained in:
2025-12-13 21:33:26 +08:00
parent 7a731d44e3
commit fa77e0a65f
2215 changed files with 392858 additions and 2 deletions

View File

@@ -0,0 +1,29 @@
## Mengya Drift Bottle Frontend
React + Vite single-page application that consumes the Flask API exposed under `/api`.
### Available Scripts
```bash
# start dev server with API proxy to http://localhost:5002
npm run dev
# lint with ESLint
npm run lint
# production build
npm run build
```
The dev server proxies every `/api/*` request to the backend, so start the Flask app before opening the React UI.
### Configuration
Set the following environment variables in a `.env` file if you need to override defaults:
```
VITE_API_BASE_URL=http://localhost:5002/api
VITE_ADMIN_URL=http://localhost:5002/admin/login
```
In production you typically serve the static build (`dist/`) behind the same origin as the backend, allowing the default relative `/api` base to keep working.