Spec-Zone.ru › htmx

load

Fires after element initialization

The load event is a synthetic event that fires immediately on element initialization, mimicking the standard DOM load event. It is not a real event and cannot be listened for, but can be used in an hx-trigger.

When It Fires

Right before htmx:after:init, providing a familiar event name for developers.

Event Detail

Empty - no additional context provided.

Example

<div hx-get="/content" hx-trigger="load">
  Loading...
</div>

This provides compatibility with standard DOM patterns.

Licensed under the Zero-Clause BSD License.
https://four.htmx.org/reference/events/load/

Spec-Zone.ru

Настройки Оффлайн Что нового Помощь О нас
Spec-Zone .ru
спецификации, руководства, описания, API