Commit 6e1c96b
committed
Register listeners early to stop htmx events from firing before they're ready
For load/revealed triggers, htmx may initiate requests immediately upon DOM
readiness, potentially before event listeners such as "htmx:afterRequest"
have been registered. Registering listeners in advance resolves this timing
issue.
It fixes a potential test failure in t/playwright/ticket_inline_edit.t
caused by the missing call to the htmx:afterRequest cleanup code. This
omission resulted in submitted data containing duplicate id parameters.1 parent e7ad3d8 commit 6e1c96b
3 files changed
+396
-396
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
141 | 141 | | |
142 | 142 | | |
143 | 143 | | |
144 | | - | |
145 | 144 | | |
146 | 145 | | |
| 146 | + | |
| 147 | + | |
147 | 148 | | |
148 | 149 | | |
149 | 150 | | |
| |||
0 commit comments