getClientRect

external fun getClientRect(): DOMRect?(source)

The getClientRect() method of the CaretPosition interface returns the client rectangle for the caret range.

MDN Reference