title: React draft wysiwyg - Can't able to type text in editor after clearing editorState
body: <p>I'm trying to reset editor content after some action completed using <code>react-draft-wysiwyg</code> editor. All contents cleared by using <code>clearEditorContent</code> method from <code>draftjs-utils</code>. But after clearing contents I can't able to type nothing in editor. Added the code below. Please help to solve this problem. </p>
  
  <pre><code>import React, { Component } from 'react';
  import { EditorState, convertToRaw, ContentState } from 'draft-js';
  import { clearEditorContent } from 'draftjs-utils'
  import { Editor } from 'react-draft-wysiwyg';
  import '../../../../node_modules/react-draft-wysiwyg/dist/react-draft-wysiwyg.css';
  import draftToHtml from 'draftjs-to-html';
  import htmlToDraft from 'html-to-draftjs';
  
  export default class RTEditor extends Component {
    constructor(props) {
      super(props);
      this.state = {
        editorState: EditorState.createEmpty(),
      };
      this.setDomEditorRef = ref =&gt; this.domEditor = ref;
    }
  
    onEditorStateChange: Function = (editorState) =&gt; {
      this.setState({
        editorState,
      }, () =&gt; {
        this.props.sendResult(draftToHtml(convertToRaw(this.state.editorState.getCurrentContent())));
      });
    };
  
    componentWillReceiveProps(nextProps) {
      if(nextProps.reset) {
        this.reset();
      }
    }
  
    componentDidMount() {
      if(this.props.text) {
        const html = `${this.props.text}`;
        const contentBlock = htmlToDraft(html);
        if (contentBlock) {
          const contentState = ContentState.createFromBlockArray(contentBlock.contentBlocks);
          const editorState = EditorState.createWithContent(contentState);
          this.setState({ editorState, });
        }
      }
  
      this.domEditor.focusEditor();
    }
  
    reset = () =&gt; {
        let {editorState} = this.state;
        editorState = clearEditorContent(editorState);
        this.setState({ editorState });
    };
  
    render() {
      const { editorState } = this.state;
      return (
        &lt;Editor
          ref={this.setDomEditorRef}
          editorState={editorState}
          wrapperClassName="rte-wrapper"
          editorClassName="rte-editor"
          onEditorStateChange={this.onEditorStateChange}
          toolbarCustomButtons={[this.props.UploadHandler]}
        /&gt;
      )
    }
  }
  </code></pre>
  
  <p>My parent component code is below,</p>
  
  <pre><code>import React, { Component } from 'react'
  import { addThreadPost } from '../../../api/thread-api'
  import { isEmpty } from '../../../api/common-api'
  import RTEditor from './Loadable'
  
  export default class ThreadActivity extends Component {
      constructor(props) {
          super(props)
          this.state = {
              clearEditor: false,
              threadPost: ''
          }
      }
  
      setPost = (post) =&gt; {
          this.setState({ threadPost: post })
      }
  
      addThreadPost = () =&gt; {
          let postText = this.state.threadPost.replace(/&lt;[^&gt;]+&gt;/g, '');
          if(!isEmpty(postText)) {
              addThreadPost(this.props.match.params.id_thread, this.state.threadPost, this.state.postAttachments).then(response =&gt; {
                  this.setState({ 
                      clearEditor: true,
                      postAttachments: [],
                  })
              });
          }
          else {
              alert("Please enter some text in box.");
          }
      }
  
      render() {
          return [
              &lt;div className="commentbox-container"&gt;
                  &lt;div className="form-group"&gt;
                      &lt;div className="form-control"&gt;
                          &lt;RTEditor 
                              ref={node =&gt; { this.threadPost = node }} 
                              text={""} 
                              sendResult={this.setPost.bind(this)}
                              reset={this.state.clearEditor}
                          /&gt;
                          &lt;button className="btn-add-post" onClick={this.addThreadPost}&gt;Add Post&lt;/button&gt;
                      &lt;/div&gt;
                  &lt;/div&gt;
              &lt;/div&gt;
          ]
      }
  }
  </code></pre>