JSFiddle - React, Tailwind, and code Playground

HTML

<textarea rows="4" cols="100" name="postcontent" onfocus="htmlHelper()" id="postcontent" required></textarea><br />

JavaScript

function htmlHelper(){
	$("#postcontent").keypress(function(e) {
    if(e.which == 13) {
        var currentHTML = document.getElementById("postcontent").value;
        var currentHTML = currentHTML + "\n<br /><br />"
        document.getElementById("postcontent").value = currentHTML;
    }
});
}