JSFiddle - React, Tailwind, and code Playground
HTML
<input value="0" id="id">
<button onclick="myFunction()">Click me</button>
<script>
function myFunction() {
document.getElementById("id").value = parseInt(document.getElementById("id").value) +10;
}
</script>