I have this setup:
<div contenteditable="true">
<span>The quick brown fox </span>
<span>jumps over the lazy dog.</span>
</div>
I need to be able to set the caret somewhere inside a span. I have found this How to set caret(cursor) position in contenteditable element (div)? which makes me able to set it inside a div, but not inside a span in the div.
Making the spans themselves contenteditable works, but I don't want that, because that way I lose the possibility to select over multiple spans.