HTMX reference architecture sandbox
My (Alan's) reference architecture for a dead simple edge worker friendly stack using CF Workers, Hono, Htmx and PicoCSS.
Repo here : https://github.com/goblinfactory/ra-htmx-hono-picocss-2024
Please note, this is not meant as a demo or as a tutorial; it's an important (deliberately minimalist) reference architecture. This allows me to quickly test htmx features safely in isolation before applying them to my production project. The source code also serves as documentation for patterns of how to apply htmx in my projects consistently, and how different problems are addressed.
To make best use of this reference archicture, if you have problems in a production project using htmx, clone the repo for this project, and build the smallest page that tests the HTMX behaviour you're using in production. Typically that is most likely a kind of compound control with some behaviours, get that working as a standalone control in the cloned project. HTMX network requests inspected using F12 dev tools are so much cleaner than most other frameworks it should often be easy to identify causes and fixes with a small spike.
See more htmx examples at htmx.org/examples/