mirror of
https://github.com/bigskysoftware/htmx.git
synced 2025-09-28 13:31:06 +00:00
Minor changes in docs (#1033)
* Minor change in active-search docs You don't want people to believe they need a POST request to run a search query. * More limitations of hx-preserve
This commit is contained in:
parent
e4f8105262
commit
d6037bde67
@ -10,8 +10,7 @@ Elements with `hx-preserve` set are preserved by `id` when htmx updates any ance
|
|||||||
You *must* set an unchanging `id` on elements for `hx-preserve` to work.
|
You *must* set an unchanging `id` on elements for `hx-preserve` to work.
|
||||||
The response requires an element with the same `id`, but its type and other attributes are ignored.
|
The response requires an element with the same `id`, but its type and other attributes are ignored.
|
||||||
|
|
||||||
Note that some elements cannot unfortunately be preserved properly, such as iframes or certain types
|
Note that some elements cannot unfortunately be preserved properly, such as `<input type="text">` (focus and caret position are lost), iframes or certain types of videos. To tackle some of these cases we recommend the [morphdom extension](/extensions/morphdom-swap/), which does a more elaborate DOM
|
||||||
of videos. In these cases we recommend the [morphdom extension](/extensions/morphdom-swap/), which does a more elaborate DOM
|
|
||||||
reconciliation.
|
reconciliation.
|
||||||
|
|
||||||
### Notes
|
### Notes
|
||||||
|
@ -17,7 +17,7 @@ We start with a search input and an empty table:
|
|||||||
</h3>
|
</h3>
|
||||||
<input class="form-control" type="search"
|
<input class="form-control" type="search"
|
||||||
name="search" placeholder="Begin Typing To Search Users..."
|
name="search" placeholder="Begin Typing To Search Users..."
|
||||||
hx-post="/search"
|
hx-get="/search"
|
||||||
hx-trigger="keyup changed delay:500ms, search"
|
hx-trigger="keyup changed delay:500ms, search"
|
||||||
hx-target="#search-results"
|
hx-target="#search-results"
|
||||||
hx-indicator=".htmx-indicator">
|
hx-indicator=".htmx-indicator">
|
||||||
|
Loading…
x
Reference in New Issue
Block a user