JSFiddle - React, Tailwind, and code Playground

HTML

<input type="text" id="date"/>

JavaScript

$("#date").datepicker({
    onClose: function (text, inst) {
     $(this).focus();  
    } 
});