Session 11 — Understanding the Backend Before Building It

M4 — Backend Infrastructure April 2026 @resist

What I Did

Stopped before writing more integration code and asked a foundational question: "What IS a backend?" Worked with Claude to understand the three-tier architecture (frontend / API layer / database) and specifically why Supabase handles auth separately from data storage. Only after I could explain it back did I continue building. Also added the profile icon and history.html for account management.

AI Interactions

The core question: Asked Claude "what is a backend?" before asking it to write any more code.

@resist — Understanding Before Building (Record #11)

Claude provided the next set of Supabase integration code and said "paste this and run it." I stopped and said — wait. I don't understand what I'm running. I spent the next 30 minutes asking questions about the three-tier model, JWT tokens, row-level security, and how the Supabase client manages auth state. Then I wrote the code. This added time but changed how I approached every backend problem that followed. The Session 19 security fix — diagnosing a UUID vs TEXT type mismatch in RLS policies — required the conceptual model built in this session.

Profile icon + history.html: Needed a place for logged-in users to view their results history. AI suggested adding it to the main navigation. I put it in a profile icon instead — nav header real estate should be reserved for test discovery, not account management.

What I Learned

Understanding before building compounds forward. The time spent in this session directly paid off in Session 19 — I wouldn't have been able to diagnose the RLS type mismatch without the model built here. The cost of understanding was 30 minutes in Session 11. The benefit was catching a silent security vulnerability in Session 19.

Also: emoji icons are fine for test targets when they communicate the interaction unambiguously. This was an exception to the Session 7 emoji rejection — context determines when simplicity wins over polish.

Quarter Question Connection

The backend is what enables "track" in "test, teach, and track." Understanding it — not just using it — means I can maintain and improve it. A tool I understand is a tool I own. A tool I don't understand is a dependency I can't debug.

What's Next

Build the Rhythm Synchronization Test prototype. Apply GAME_STANDARD phases from the first line of code.

← Session 10 Session 12 →