</> htmx
🚧 htmx 4.0 is under construction. Read changes →

hx-config

The hx-config attribute allows you to configure request behavior using JSON.

Syntax

<button hx-post="/api/users" hx-config='{"timeout": 5000}'>
    Create User
</button>

Notes

Examples

<button hx-post="/api/users" hx-config='{"timeout": 5000}'>
    Create User (5 second timeout)
</button>