The Upsidedown Stack: React on the Server and Postgres in the Browser
summary
Built a multiplayer realtime browser game that runs a local Postgres using pgLite (3MB), syncs to a Neon remote Postgres via electric sync, and uses the useLiveQuery hook so UI automatically re-renders on local SQL changes. A Node server still validates picks for auth and game logic. Multitab sync, IndexedDB persistence, and client-side PGVector demos work, but syncing requires Postgres views, the DX is rough, and an early bug needed a weekend fix.
AI-written summary · about
chapters (10)
- 0:00Introduction and game demo
- 3:57Why apps need backends
- 9:45The backendless stack
- 11:31Introducing PGLite
- 13:39PGLite use cases
- 16:04Syncing PGLite with Postgres
- 17:51PGLite challenges and alternatives
- 20:45Sync engines and developer experience
- 22:13Future of sync engines
- 23:17Closing and 5K invite
related talks
28mPowering React-based Dashboards using GraphQL and PostgreSQL
51mBuilding a Realtime "Backend in a Box" with PostgreSQL and Vue
30mPostgreSQL & NodeJs as Core Feature of Backend for Frontend
27mMaking Games With React and Redux
45mBuilding Scalable APIs: PostgreSQL Meets GraphQL
26mCompiling Postgres to WASM with PGlite
35mGoing fullstack React(ive)
26mPouchDB and SQLDown
