JSFiddle - React, Tailwind, and code Playground

HTML

<input type="text" value="input" />

<textarea>textarea content</textarea>

JavaScript

$('textarea').on('focus', function(){
    var content = $(this).val();
    alert(content);
});