💭 How to configure base url for all requests using HTMX? - Stack...

Here's my thought on 💭 How to configure base url for all requests using HTMX? - Stack...


Today I learned how to configure the baseurl for htmx using the tag. This is pretty handy to be able to configure different baseurls.


  <base href="<scheme>://<netloc>/api/v1/">
  <button hx-post="clicked"
       hx-trigger="click"
       hx-target="#parent-div"
       hx-swap="outerHTML">
    Click Me!
  </button>

Note

This post is a thought. It's a short note that I make about someone else's content online. Learn more about the process thoughts

This post was a thought by Waylon Walker see all my thoughts at https://waylonwalker.com/thoughts