Every time I use Element.getClientRects()
, it always gives me a collection containing just one DOMRect
object.
Under what circumstances does Element.getClientRects()
return a collection with multiple DOMRect
objects?
function handleClick() {
console.log(event.target.getClientRects())
}
<ul
style="border: 1px solid black;"
onclick="handleClick()"
>
<li>Click the text to view in console</li>
</ul>