JSFiddle - React, Tailwind, and code Playground

HTML

<textarea id = "textarea">change this</textarea>
<div onclick = "change()">click here<div>
    
<script>
    function change()
    {
        document.getElementById( 'textarea' ).innerHTML = 'new text';
    }
</script>