From 847a5b8b326bed4ef5e5e072aa5eea101edc6ca5 Mon Sep 17 00:00:00 2001 From: Sawyer Date: Wed, 30 Sep 2026 07:44:36 -0700 Subject: [PATCH] docs: remove HUB_STATIC_DIR claims the hub doesn't implement (CL-9612) --- apps/hub/README.md | 6 +++--- apps/web/README.md | 15 ++++++++------- apps/web/package.json | 2 +- apps/web/vite.config.ts | 5 ++--- 4 files changed, 14 insertions(+), 14 deletions(-) diff --git a/apps/hub/README.md b/apps/hub/README.md index fc87553e72..47765b08a6 100644 --- a/apps/hub/README.md +++ b/apps/hub/README.md @@ -21,9 +21,9 @@ native tenant middleware. - There are no local `src/*-mount.ts` wiring helpers: each extension's routes mount directly in `src/index.ts` with the shared DB handle/config passed inline at the `app.route(...)` call site. -- Serves the built `apps/web` SPA from its own origin - (`HUB_STATIC_DIR` points at `apps/web/dist`), so every `/api` call the - interface makes is same-origin. +- Serves no static files. In dev, `vite dev` (apps/web) serves the SPA and + proxies `/api` to the hub; in e2e, `e2e/lib/browser.ts` serves the built + `apps/web/dist` itself, in front of the hub, on one origin. - `credential-expiry-sweep.ts`, `workflow-scheduler.ts`, and `inbox-unsnooze-sweep.ts` are host-level periodic sweeps wired at boot, alongside the route mounts; `cron-due.ts` is a re-export seam onto diff --git a/apps/web/README.md b/apps/web/README.md index 06b76ec126..c20b259633 100644 --- a/apps/web/README.md +++ b/apps/web/README.md @@ -2,13 +2,14 @@ The workbench's single-page interface: every screen and route lives here, composed from the published `@corbits/react-ui` component library, and -builds to a static bundle the hub serves from its own origin (`vite -build`, then point `HUB_STATIC_DIR` at `apps/web/dist`). It is a Vite SPA -over the hub's `/api` — every product rule (what a screen may show, how -data is shaped) lives in a package; this app stays a generic composition -of package UI and routing, per [AGENTS.md](../../AGENTS.md). In dev, -`vite dev` proxies `/api` to a locally running hub so the interface is -developed against real data without a build step. +builds to a static bundle in `dist/` (`vite build`). The hub serves no +static files. It is a Vite SPA over the hub's `/api` — every product rule +(what a screen may show, how data is shaped) lives in a package; this app +stays a generic composition of package UI and routing, per +[AGENTS.md](../../AGENTS.md). In dev, `vite dev` serves the SPA and proxies +`/api` to a locally running hub, so the interface is developed against real +data without a build step. In e2e, `e2e/lib/browser.ts` builds and serves +`dist/` itself on the same origin as the hub. ## Layout diff --git a/apps/web/package.json b/apps/web/package.json index f8e8609909..25d05a44fd 100644 --- a/apps/web/package.json +++ b/apps/web/package.json @@ -2,7 +2,7 @@ "name": "@workbench/web", "version": "0.0.1", "private": true, - "description": "Single-page interface for the workbench: every page and route lives here, composed from the published component library, and builds to a static bundle the hub serves from its own origin (point HUB_STATIC_DIR at apps/web/dist)", + "description": "Single-page interface for the workbench: every page and route lives here, composed from the published component library, and builds to a static bundle in dist/", "license": "SEE LICENSE IN ../../LICENSE.md", "repository": { "type": "git", diff --git a/apps/web/vite.config.ts b/apps/web/vite.config.ts index 1f6e0c6948..a0d7ea5dee 100644 --- a/apps/web/vite.config.ts +++ b/apps/web/vite.config.ts @@ -1,6 +1,5 @@ -// The build lands in apps/web/dist with root-relative asset URLs; point the -// hub's HUB_STATIC_DIR at that directory and the interface is served from the -// hub's own origin, so every /api call is same-origin with no CORS setup. +// The build lands in apps/web/dist with root-relative asset URLs. The hub +// serves no static files; e2e/lib/browser.ts serves dist itself. // // `vite dev` proxies /api to a locally running hub so the interface can be // developed against real data without a build step.