JSFiddle - React, Tailwind, and code Playground
HTML
<select id="s">
<option>Cat</option>
<option>Mat</option>
</select>
<button id="b">De-select</button>
<hr/>
<select id="s2" multiple>
<option selected>Cat</option>
</select>
<button id="b2">De-select</button>
JavaScript
document.getElementById('b').onclick = function() {
var sel = document.getElementById('s');
sel.selectedIndex = -1;
};
document.getElementById('b2').onclick = function() {
var opts = document.getElementById('s2').options;
for (var i = 0, opt; opt = opts[i]; i++) {
opt.selected = false;
}
};