Mentioned, how to submit and reset a form on success using htmx:
hx-target="#candidates_add_form"hx-swap="beforebegin"
hx-on::after-request=" if(event.detail.successful) this.reset()"
>
This assumes the last row is the add form, and places the newly added item directly above it.
Fler avsnitt av hx-pod
Visa alla avsnitt av hx-podhx-pod med Lazarus finns tillgänglig på flera plattformar. Informationen på denna sida kommer från offentliga podd-flöden.
