title: get value from onInput event for cotentEditable in React
body: <p>I have a contentEditable header in which I want to get the value on <code>onInput</code> event. So far, I have managed to get <code>event.target</code> but it returns the entire DOM node. I want to get only the actual value of the header. Helpful ideas are highly appreciated.</p>
  
  <p>What I have tried so far:</p>
  
  <ol>
  <li><p><code>console.log(e.target.value)</code> --> returns <code>undefined</code></p></li>
  <li><p><code>console.log(e.target)</code> --> returns the node <code>&lt;h5 contenteditable="true" style="margin: 0px;"&gt;Lesson 1&lt;/h5&gt;</code></p></li>
  <li><p>I also thought to convert node to string and extract the value using reg ex, but I had to give up when <code>console.log(e.target.toString())</code> return <code>[object HTMLHeadingElement]</code></p></li>
  </ol>
  
  <pre class="lang-js prettyprint-override"><code>&lt;h5 contentEditable style={{ margin: 0 }} onInput={e =&gt; {
            props.onChangeName(e.target.value)
            console.log(e.target)
        }}&gt;
          {props.name}
  &lt;/h5&gt;
  </code></pre>