Closed
Description
Current spec for CaretPosition
interface has a caret range
concept which is a live range. The caret range
is only used to get the client rect of the CaretPosition
. We should avoid creating the live range upfront because:
- the live range is not used at all except for getting client rect.
- Maintain live range can be expensive during DOM mutation.
- No browsers implemented the algorithm by creating live range upfront. (Firefox and Chromium both create a live range only when
CaretPosition::getClientRect()
is invoked.)
Propose to remove caret range
concept from CaretPosition
interface.