Build bricks together in a shared isometric world.
Hyperspace is the demo app for Real-Time Hypermedia (the htmx way). It uses FastAPI, PostgreSQL, htmx, and CSS.
Play Hyperspace · View the source
Browser actions send normal HTTP requests. FastAPI updates PostgreSQL, renders the shared world as HTML, and pushes it to every browser over a compressed multipart stream.
Two htmx 4 extensions connect the server-rendered world to local interactions:
hx-multipartconsumes the stream and morphs each update into#world. It vendors the parser fromfetch-multipart.hx-liveupdates reactive attributes for local prediction, controls, and status text.
multipart-response provides FastAPI multipart response support. It is installed while the current stream route moves from its custom response to MultipartResponse.
Client-side prediction keeps brick actions responsive while the server remains the source of truth.
Start the app with Docker:
just up -d --buildOpen localhost:8000, then run the tests:
just testStart the production stack on port 8000 using this Mac's LAN address:
just demoThe command prints the URL for demo devices and configures the join QR code:
Demo: http://192.168.1.23:8000
Reproduce the result:
uv run python -m bench.compressionSee BENCHMARK.md for the workload, limits, and longer runs.
Commit every change, then deploy main:
git push origin main
just deployjust deploy checks for a clean working tree, pushes main, deploys it to the ThinkCentre, and waits for the public health check.


