JSFiddle - React, Tailwind, and code Playground

HTML

<input inputmode="number">
<button>What did I type?</button?

JavaScript

$('[inputmode]').each(function () { $(this).attr({type: $(this).attr('inputmode'), novalidate: true}) });

$('button').click(function alertInput () {
    alert($('input').val());
})