Requests

  • hx-get - issues GET request to specified URL
  • hx-post - issues POST request to specified URL
  • hx-put - issues PUT request to specified URL
  • hx-patch - issues PATCH request to specified URL
  • hx-delete - issues DELETE request to specified URL
  • hx-query - issues QUERY request to specified URL

Request Control

  • hx-trigger - controls when element issues requests
  • hx-swap - controls how response is inserted
  • hx-target - controls where response is inserted
  • hx-select - controls which response part is inserted
  • hx-swap-oob - marks response elements to swap into page by ID
  • hx-select-oob - picks response elements to swap into page by ID
  • hx-confirm - shows confirmation dialog before request

Scripting

  • hx-on - runs inline JavaScript when event fires

Data

History

Enhancements

  • hx-boost - converts links and forms to AJAX
  • hx-preload - preloads content before user triggers request
  • hx-pending - shows custom content during requests

Advanced