JSFiddle - React, Tailwind, and code Playground

HTML

<script src="https://ajax.googleapis.com/ajax/libs/jquery/2.1.1/jquery.min.js"></script>
type a number then submit to see cents formatted to dollars <br>
<input type="text" value="100" id="mw_amount">
<input type="submit" class="submit">

JavaScript

var theField = $("#mw_amount");
$(".submit").click( function(){
    var theFieldVal = $("#mw_amount").val();
    var formatedVal = '$' + (theFieldVal / 100).toFixed(2);
    $("#mw_amount").val(formatedVal);
});