Search code examples
javascriptreactjstinymce

TinyMCE input being written in reverse order


I am facing this issue where whenever I type in TinyMCE my cursor shifts to left automatically and I end up writing text from right to left. Its only happening in my deployed application but same works fine if I run the code locally on my machine. Any possible reason why this might be happening?

screenshot for same

Note: This was working fine few days ago


Solution

  • The below answer worked for me as well, went to project github but did not find any bug, so submitted one now, https://github.com/tinymce/tinymce-react/issues/267

    Here is the actual answer from TinyMCE as to how to fix this issue:

    Change this line:

    initialValue={blogContent}

    to

    value={blogContent}

    The initialValue prop should only be set once. It resets the editor including the cursor position when it changes.