Voices
htmx 4.0 ships: fetch() replaces XMLHttpRequest and attribute inheritance becomes opt-in via :inherited
Carson Gross released htmx 4.0.0 on August 28 after eight months of work, skipping htmx 3 to keep an old promise never to ship a backwards-incompatible 3.x. fetch() replaces XMLHttpRequest as the core ajax layer, which changes the events model, and the bigger practical break is that props like hx-target no longer inherit implicitly, requiring hx-target:inherited="#div". There is a CLI tool to find the places needing the modifier and an htmx-2-compat extension that restores the old behavior during migration.
Source
↳ Follow the thread