JSFiddle - React, Tailwind, and code Playground
HTML
<input type=text name=v1><br>
<input type=text name=v2><br>
<input type=text name=v3><br>
<input type=text name=v4><br>
<input type=text name=v5>
JavaScript
$( "input[type=text]" ).on("keyup", function() {
var o,v=(o=$(this)).val();
o.val(v.replace(/[^\d]/g,""));
});