observe
specifies the target node and callback, and the target node is specified according to id
.
Specify the id used when searching for the target node. The id
will be searched first in the component
passed in when creating the IntersectionObserver
object. If not found, the global search will be performed. If the global search is not found, the specification will be invalid.
Specify the callback triggered when the intersection status of the target node and the reference node changes.
The format of the callback parameter res
is as follows:
The structures of intersectionRect
, boundingClientRect
and relativeRect
are the same. The coordinate systems are all relative to LynxView
, that is, the upper left corner of LynxView
is the origin of the coordinate system, with the horizontal direction to the right being the positive direction of the x
-axis, and the vertical direction being downwards being the positive direction of the y
-axis:
None (undefined
).
LCD tables only load in the browser