JSFiddle - React, Tailwind, and code Playground
by Bob Stein
HTML
<script src="http://stackoverflow.com/a/14614750/673991"></script>
For StackOverflow answer to <a href="http://stackoverflow.com/a/14614750/673991" target="_blank">HTML combo box with option to type an entry</a>
<h2>HTML4: SELECT + INPUT</h2>
<select name="example">
<option value="">Other</option>
<option value="A">A</option>
<option value="B">B</option>
</select>
<input type="text" name="other">
<h2>HTML5: DATALIST</h2>
<input type="text" name="example" list="exampleList">
<datalist id="exampleList">
<option value="A">
<option value="B">
</datalist>
JavaScript
$(document).ready(function () { // Help for the HTML4 version.
$('select[name=example]').change(function () {
$('input[name=other]').val($(this).val());
});
});