Fork me on GitHub
#solo-full-stack
<
2023-09-19
>
ianjones16:09:15

I’ve been building a biff-powered workout log book with my brother. working on the single-player experience, then going to work on monetization (getting gyms to buy into the platform and host it for their members)

😎 5
💪 5
🚀 3
ianjones16:09:50

my brother helps out with design and ux and then I implement

ianjones16:09:05

slowly roping him into learning clojure

rich 1
clojure-spin 2
Lyn Headley12:09:44

This is a very interesting interface, relatively complex for something built with htmx. Thank you for sharing. I am trying to imagine how you built it and would be very interested in a write up or further details, lessons learned or pain points.

ianjones21:09:47

yeah for sure. The tldr is that any interaction you have with an htmx page usually needs its own endpoint to handle that interaction and return the new state to the client. The fact that the client doesnt have to manage any state makes it a lot simpler (at least in my head) around what you need to return in your handler

ianjones21:09:42

I built this a couple weeks ago too which was a lot of fun to figure out.. https://twitter.com/_jonesian/status/1696745494440272216?s=20

Lyn Headley12:10:53

Okay so the server returns state to the client. When the client submits a request to the server, does it also submit all of the state that previous interactions have generated? Or does it only selectively submit some parts of that state?

ianjones14:10:54

selectively submits state that you choose, by default the state of the element the user just interacted with. Although you can add more to the request if you need state from somewhere else