Using textarea in textarea problem

I want to use a form with have textarea but when i start use textarea in textarea my codes are deleting and i can’t see after close textarea.

That has nothing to do with CodeMirror, but you want to HTML-escape the tags inside the textarea (<textarea>).