Merge remote-tracking branch 'origin/master'

This commit is contained in:
Carson Gross 2023-08-16 12:19:39 -06:00
commit 193a9ea9d2

View File

@ -24,6 +24,23 @@ This button will issue a `GET` to `/info` and then select the element with the i
which will replace the entire button in the DOM, and, in addition, pick out an element with the id `alert`
in the response and swap it in for div in the DOM with the same ID.
Each value in the comma separated list of values can specify any valid [`hx-swap`](@/attributes/hx-swap.md)
strategy by separating the selector and the swap strategy with a `:`.
For example, to prepend the alert content instead of replacing it:
```html
<div>
<div id="alert"></div>
<button hx-get="/info"
hx-select="#info-details"
hx-swap="outerHTML"
hx-select-oob="#alert:afterbegin">
Get Info!
</button>
</div>
```
## Notes
* `hx-select-oob` is inherited and can be placed on a parent element