JSFiddle - React, Tailwind, and code Playground
by Ohgodwhy
HTML
<select>
<option text="ok">1</option>
<option text="hello">2</option>
<option text="test">3</option>
</select>
<input type="text" />
JavaScript
$(function(){
$('select').on('change', function(){
$('input').val($('option:selected', this).attr('text'));
});
});