Skip to content

fix(website): relative asset base — subpath deploy rendered a blank page - #614

Merged
gHashTag merged 1 commit into
mainfrom
fix/website-relative-base
Aug 8, 2026
Merged

fix(website): relative asset base — subpath deploy rendered a blank page#614
gHashTag merged 1 commit into
mainfrom
fix/website-relative-base

Conversation

@gHashTag

@gHashTag gHashTag commented Aug 8, 2026

Copy link
Copy Markdown
Owner

Follow-up to #611 and #612. Those got the deploy running and pointed Pages at the right branch — https://t27.ai/trinity/ finally returns 200. It served a blank page.

Cause

apps/website/vite.config.ts had:

base: '/', // Custom domain t27.ai (no subpath)

That emits absolute asset URLs. But GitHub Pages serves this repo as a project site under /trinity/, so index.html requested /assets/index-*.js — which resolves to the apex root, where that file does not exist:

404  https://t27.ai/assets/index-C0-LRwGj.js      ← what the page asked for
200  https://t27.ai/trinity/assets/index-C0-LRwGj.js  ← where it actually lives

No bundle → no React → empty <body>. The HTML and the assets were both deployed correctly; only the addressing was wrong.

Fix

base: './' — assets are addressed relative to wherever index.html sits, so the same build works at the apex and under /trinity/. This is safe here specifically because routing is HashRouter: there is no server-side path resolution that a relative base could confuse.

Also made manifest.json relative for the same reason.

Verification

Built output now contains zero absolute local paths:

href="manifest.json"
src="./assets/index-BRyDDFc_.js"
href="./assets/three-ZxykV9TK.js"
href="./assets/index-BQVTNvXP.css"

After this deploys I will load the page in a real browser and confirm it renders — the previous "200 OK" was not proof that anything worked.

🤖 Generated with Claude Code

…m a subpath

The deploy finally reached the web and served a blank page.

Cause: vite `base: '/'` emits absolute asset URLs. GitHub Pages serves this
repository as a project site under /trinity/, so index.html asked for
/assets/index-*.js — which resolves to the apex root, where that file does not
exist (404). No bundle, no React, blank page. Verified directly:

  404  https://t27.ai/assets/index-C0-LRwGj.js
  200  https://t27.ai/trinity/assets/index-C0-LRwGj.js

Fix: `base: './'` so assets are addressed relative to wherever index.html sits —
correct at the apex AND under /trinity/. Safe because routing is HashRouter, so
there is no server-side path resolution to worry about.

Also made the manifest link relative for the same reason. Build output now has
zero absolute local paths.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
@gHashTag
gHashTag merged commit f882bed into main Aug 8, 2026
9 of 18 checks passed
@gHashTag
gHashTag deleted the fix/website-relative-base branch August 8, 2026 08:10
github-actions Bot added a commit that referenced this pull request Aug 8, 2026
fix(website): relative asset base so the site renders when served from a subpath (#614)

The deploy finally reached the web and served a blank page.

Cause: vite `base: '/'` emits absolute asset URLs. GitHub Pages serves this
repository as a project site under /trinity/, so index.html asked for
/assets/index-*.js — which resolves to the apex root, where that file does not
exist (404). No bundle, no React, blank page. Verified directly:

  404  https://t27.ai/assets/index-C0-LRwGj.js
  200  https://t27.ai/trinity/assets/index-C0-LRwGj.js

Fix: `base: './'` so assets are addressed relative to wherever index.html sits —
correct at the apex AND under /trinity/. Safe because routing is HashRouter, so
there is no server-side path resolution to worry about.

Also made the manifest link relative for the same reason. Build output now has
zero absolute local paths.

Co-authored-by: Dmitrii Vasilev <admin@t27.dev>
Co-authored-by: Claude Opus 5 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant