Web features explorer

Selection composed ranges

Limited availability
Tags: api Groups: Selection Web Components

The window.getSelection().getComposedRanges() method returns ranges that represent the current user selection, even if the selection spans across shadow tree boundaries. To learn more, see Selection: getComposedRanges() method at MDN.

Compatibility