mirror of
https://github.com/bigskysoftware/htmx.git
synced 2025-10-02 07:21:05 +00:00
Merge pull request #611 from jgirardet/patch-1
add missing intersect in reference + a tips when using overflow
This commit is contained in:
commit
0686aa5399
@ -88,7 +88,10 @@ The response from the `/search` url will be appended to the `div` with the id `s
|
||||
There are two special events that are non-standard that htmx supports:
|
||||
|
||||
* `load` - triggered on load (useful for lazy-loading something)
|
||||
* `revealed` - triggered when an element is scrolled into the viewport (also useful for lazy-loading)
|
||||
* `revealed` - triggered when an element is scrolled into the viewport (also useful for lazy-loading). If you are using `overflow` in css like `overflow-y: scroll` you should use `intersect once` instead of `revealed`.
|
||||
* `intersect` - fires once when an element first intersects the viewport. This supports two additional options:
|
||||
* `root:<selector>` - a CSS selector of the root element for intersection
|
||||
* `threshold:<float>` - a floating point number between 0.0 and 1.0, indicating what amount of intersection to fire the event on
|
||||
|
||||
### Triggering via the `HX-Trigger` header
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user