JSFiddle - React, Tailwind, and code Playground

by ibroom

HTML

<form>
  <label for="field1">
    number field that supports 2 decimal places
  </label>
  <input type="number" id="field1" step="0.01" value="1.23"/>
  <br/>
  <label for="field2">
    a range field that goes from 3 to 15
  </label>
  <input type="range" id="field2" min="3" max="15" value="3" oninput="field2out.value=field2.value">
  <output id="field2out">3</output>
  <br>
  <label for="field3">
    a telephone number field that validates the telephone number
  </label>
  <input type="tel" id="field3" pattern="[0-9]{10}"> 
  <input type="submit">
</form>