News for hackers. Stuff that matters.
Re:HTMX is hard, so let's get it right by yawaramin on Tuesday August 05, 2025 @01:50AM (#44794717)
Looking at the solution you ended up with, I feel like it's actually fairly reasonable in terms of implementation complexity compared to the feature it is delivering. I have a hard time believing that a pure SPA approach would be simpler to implement. Certainly a SPA would deliver a much more bloated JS payload to the client, which really doesn't seem like a good tradeoff for basically filling out a form and uploading a couple of files.
Re:HTMX is hard, so let's get it right by bookofcooks on Tuesday August 05, 2025 @11:21AM (#44799187)
> I have a hard time believing that a pure SPA approach would be simpler to implement.

IF you used a pure SPA approach with client-side validation for each step, and server-side validation only done at the last step, I believe it would be simpler.

However, let's say you introduce anything slightly more complicated. Like say you do server-side validation with each step, now you have to somehow persist that "validated data". In that case, the implementation in the article is indeed simpler (or at least not as complicated as a traditional SPA).