JSFiddle - React, Tailwind, and code Playground

by Akram kamal

HTML

<label for="currency">Currency</label>
<select id="currency" name="currency">
    <option value="$">US $</option>
    <option value="€">EUR €</option>
    <option value="¥">YEN ¥</option>
</select>
<br/>
<label for="amount">Select the amount to donate:</label>
<input id="amount" name="amount" value="5" />

JavaScript

var currency = $("#currency").change(function() {
    $("#amount").spinner("option", "currency", $(this).val()).blur();
});
$("#amount").spinner({
    currency: currency.val(),
    min: 5,
    max: 1000,
    step: 5
});