JSFiddle - React, Tailwind, and code Playground
HTML
<select id="selectId">
<option value="hello">Foo</option>
</select>
JavaScript
$("#selectId > option").each(function() {
alert(this.text + ' ' + this.value);
});
<select id="selectId">
<option value="hello">Foo</option>
</select>
$("#selectId > option").each(function() {
alert(this.text + ' ' + this.value);
});