JSFiddle - React, Tailwind, and code Playground
HTML
<p>Date:
<input type="text" id="datepicker" />
</p>
JavaScript
$(function () {
$("#datepicker").datepicker({
dateFormat: "yy-mm-dd",
onSelect: function () {
window.open(document.URL + '?date=' + this.value);
}
});
});