JSFiddle - React, Tailwind, and code Playground

HTML

<label class="description" for="element_1">Email Address </label>
<div>
    <input id="element_1" name="email" class="element text medium" type="text"/> 
    <div class="field_error">form.email.errors</div>
</div>

CSS

.field_error{color:red;}
.red_border{border:1px solid red;}

JavaScript

$.each( $('.field_error'), function() { 
console.log('hello '+$(this).text());
$(this).addClass( 'red_border' );
});