JSFiddle - React, Tailwind, and code Playground
HTML
<textarea class="mydesc" style="width: 200px; height: 200px;">
11111111 1
111 111 11
11 11 11 1
</textarea>
JavaScript
$('.mydesc').keyup(function () {
this.value = this.value
.replace(/[\n\r]+/g, "")
.replace(/(.{10})/g, "$1\n");
});