chore: document env files and configure proxy target
Add VITE_PROXY_TARGET to the example environment file and use it in the Vite dev proxy configuration with a localhost fallback. Expand the LLM development guide with env file loading order, version-control rules, and variable descriptions. Also clean up ignored local tool paths in .gitignore and remove duplicated README env examples.chore: document env files and configure proxy target Add VITE_PROXY_TARGET to the example environment file and use it in the Vite dev proxy configuration with a localhost fallback. Expand the LLM development guide with env file loading order, version-control rules, and variable descriptions. Also clean up ignored local tool paths in .gitignore and remove duplicated README env examples.
This commit is contained in:
@@ -67,15 +67,6 @@ pnpm dev
|
||||
cp .env.example .env
|
||||
```
|
||||
|
||||
常用設定:
|
||||
|
||||
```env
|
||||
VITE_API_BASE_URL=/service/api
|
||||
VITE_SKIP_LOGIN=false
|
||||
VITE_DEV_DEFAULT_USER_ID=
|
||||
VITE_DEV_DEFAULT_PASSWORD=
|
||||
```
|
||||
|
||||
`client.ts` 會優先使用 `VITE_API_BASE_URL`,否則預設 `/service/api`。開發模式下,Vite proxy 會將 `/service/*` 轉送到後端。
|
||||
|
||||
實際 `.env` 與 `.env.*.local` 不應提交。production API URL 應由使用專案自己的部署環境提供。
|
||||
|
||||
Reference in New Issue
Block a user