Avoid caret move during a textarea live update
<p>I would like to create something similar to google doc in html. More than one people can edit the same file at the same time, a live edit very similar to google doc.</p>

<p>On the server side, everything is ok (I use play2 and akka) but on client side (in javascript):</p>

<ol>
<li>If I update the text without typing, the caret position stay at the same place in the text area</li>
<li>If user types when the textarea is updated, <strong>caret position go at the end</strong> of the textarea and this is really annoying. </li>
</ol>

<p>Mechanism of update is a cometd. It can update the textarea at any moment.</p>

<p>Do you have an idea or component who support live update in JS ? Synchonization in javascript (or jQuery) or something else ? :) Do you know how google implement it in google doc ?</p>

<p>Thank you for your help</p>
