feat: add taro h5 runtime deployment config

This commit is contained in:
Codex
2026-06-30 01:19:14 +08:00
parent b8242429bb
commit 25d1b8e796
16 changed files with 370 additions and 78 deletions

View File

@@ -120,6 +120,20 @@ apps/taro/dist/h5-platform-admin
推荐分别部署到学生端域名、租户后台域名、平台后台域名;三者共用 `apps/taro/src/services/api.ts` 请求层,业务数据默认调用 `apps/api`,不要在页面里直写 Supabase 表。
H5 线上推荐每个静态目录放独立 `runtime-config.json` 覆盖公开配置,避免 API/Auth 域名变化时重打包:
```text
apps/taro/deploy/h5-student.runtime-config.example.json
apps/taro/deploy/h5-tenant-admin.runtime-config.example.json
apps/taro/deploy/h5-platform-admin.runtime-config.example.json
```
部署时把示例复制为对应 Web 根目录的 `runtime-config.json`,只填写 `portal``apiBaseUrl``supabaseUrl``supabasePublishableKey``tenantCode` 这类公开字段。完整 Nginx、CSP、缓存、CORS 和三域名部署说明见:
```text
docs/refactor/taro-h5-deployment.md
```
学生端当前页面:
```text