Re: [whatwg/dom] Introduce a StaticRange constructor (#590)

Hi all! I work on the Microsoft Edge team and we were interesting in using static ranges as part of our Highlight API proposal. In case you’re unfamiliar with the highlight API, it provides a way for web developers to style the text inside arbitrary ranges within the DOM, which can be useful for editing applications that are trying to implement their own selection, find-on-page, spellchecking, etc. If you would like more details, please refer to this explainer: https://github.com/MicrosoftEdge/MSEdgeExplainers/blob/master/highlight/explainer.md. We believe the highlight API is a great use case for StaticRange; however, we would need StaticRanges to be constructible, so that authors can create these range objects and add them to one or more HighlightRangeGroups (see examples in the explainer).

From reading the responses here as well as [https://github.com/w3c/staticrange/issues/3](https://github.com/w3c/staticrange/issues/3), it sounds like there is general agreement about giving StaticRange a constructor and we’re just trying to iron out whether we need input validation. Is that correct? If so, I was wondering if there has been any further discussion on this topic (possibly elsewhere) or if we could pick this up again? I’m also happy to help drive this forward if needed.

-- 
You are receiving this because you are subscribed to this thread.
Reply to this email directly or view it on GitHub:
https://github.com/whatwg/dom/issues/590#issuecomment-518381030

Received on Monday, 5 August 2019 20:12:20 UTC