Skip to content

0025 one web app

github-actions[bot] edited this page Nov 18, 2026 · 4 revisions

One TanStack Start app is the website, on GitHub Pages

Status: accepted · Implementation: done · Date: 2026-11-18

From LibreLifts ADRs 0010 and 0019. The address librebars.app is assumed and has to be confirmed before the first publish. In LibreLifts only the product page and an account placeholder were built; the same is planned here first. As built, 2026-11-18: the home page and the account placeholder, prerendered, with the build check and the Pages workflow. The content security policy is the one LibreLifts arrived at. An address the build did not produce shows the not-found page through 404.html, with a hydration warning from React in the console. Nothing is published: main has not moved, Pages is not switched on, and there is no CNAME file because the domain is not confirmed. So this stays planned. First publish 2026-11-18, when main was moved to dev without a release: the site went out at vindotski.github.io/librebars built for the root of a domain, so its stylesheet and scripts were not found. The build now takes the path and the address it is served at as settings, and the Pages workflow sets them. The github-pages environment had to be told that main may deploy. The domain is still not confirmed, so this stays planned. Done on 2026-11-18: the domain librebars.app was confirmed and set on the repository, with DNS at Cloudflare pointing at GitHub Pages and HTTPS enforced. The site is built for the root again and public/CNAME holds the domain. The sentences above that say the domain is not confirmed and that this stays planned describe the hours before that.

Context

The web has several jobs: say what LibreBars is, hold documentation for people who use it, a blog, later a page for every exercise in the open database, and a dashboard where someone manages their account. The dashboard is an application, not a document. The choice is between several projects or one that does it all. TanStack Start can prerender some routes to static files and leave others to render in the browser.

Decision

  • apps/web is one TanStack Start app for the product pages, the docs, the blog, the catalog and the account dashboard. One deployment and one look.
  • Content pages are prerendered to static files. Pages behind a sign-in render in the browser and stay out of the sitemap.
  • It is hosted on GitHub Pages and published from main, by .github/workflows/pages.yml. No server functions and no server routes are used while it is hosted there.
  • The site makes no requests to other origins. Fonts are self-hosted, and the build fails if a page loads anything from another origin or if a link on a page does not resolve.
  • The content security policy is the strictest one that still lets the pages run.
  • Nothing in apps/web may depend on GitHub Pages, so that moving to a host that renders on request is a change of configuration (0026).
  • The first thing built is the product page and a placeholder for the account. The rest is added when there is something to put in it.

Consequences

  • One router, one design and one deployment for everything on the web.
  • Every page ships JavaScript, including pages that are only text.
  • On GitHub Pages an address the build did not produce is served through 404.html with a 404 status. That is acceptable for pages behind a sign-in.
  • A change to the website is not live until the next release (0003).
  • The website depends on GitHub being up, and on a domain being held and renewed.

LibreBars

Clone this wiki locally