JSFiddle - React, Tailwind, and code Playground
HTML
<script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8.2/jquery-ui.min.js"></script>
<input id="holidayDate" type="text" />
<input id="tags"></input>
JavaScript
$(document).ready(function() {
$('#holidayDate').datepicker();
$("#tags").autocomplete({source:availableTags});
var availableTags = {
"12/25": "Christmas Day",
"01/01": "New Years Day",
"02/02": "Groundhog Day",
"02/14": "Valentine's Day",
"04/22": "Earth Day",
"10/12": "Columbus Day",
"07/04": "Independence Day",
"10/31": "Halloween",
"11/11": "Veterans Day",
"12/07": "Pearl Harbour Remembrance Day",
}
$('#holidayDate').change(function() {
// Check our object map for the date, default to "" if there isn't one.
$('#tags').val(availableTags[$(this).val().substring(0, 5)] || "");
});
});