JSFiddle - React, Tailwind, and code Playground
HTML
<div id="output-text">
hello folks
</div>
<select id="input-font" class="input" onchange="changeFont (this);">
<option value="Times New Roman" selected ="selected">Times New Roman</option>
<option value="Arial">Arial</option>
</select>
<br>
<script>
function changeFont(font){
document.getElementById("output-text").style.fontFamily = font.value;
}
</script>