title: Caret position resets in contenteditable when setting innerHTML
body: <p>I'm trying to create a container field component, I'm using the html attribute <code>contenteditable</code>, but when I replace the <code>innerHTML</code> value of my component the cursor(caret) puts it back to position 0. is there a way to keep the cursor position?</p>
  
  <p>Its look like that:</p>
  
  <p><a href="https://i.stack.imgur.com/8JsOH.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/8JsOH.png" alt="enter image description here"></a></p>