I never worked with HTMX, but I think that frameworks like next.js or Astro, that can render server side and client side with the same code, are superior.
HTMX may work well for many websites though, especially if they are using mostly static content with limited interactivity.