JSFiddle - React, Tailwind, and code Playground

HTML

<div id="form">
<input type="text" />
<br />
<input type="text" />
<br />
<input type="text" />
</div>

CSS

#form{
    padding: 10px;
}

input { 
    margin-bottom: 10px;    
}

JavaScript

var $inputs = $('#form').find('input');

alert('load');

//$inputs.each(function(){
//$(this).trigger('blur');
//});
$inputs.trigger('blur');

alert('after the blur');

$inputs.blur(function(){
    var $this = $(this);
    if ($this.val() == ''){
    alert('it works');
    }
});