JSFiddle - React, Tailwind, and code Playground
by Liam Talbot
HTML
<form>
<input type='text' id='input' />
<input type="button" id="update" value="Submit" />
</form>
<div id="box">
</div>
JavaScript
$(document).ready(function() {
$('#update').click(function() {
var x = $('#input').val();
for(var i=0 ; i < x; i++) {
$('<input type="text" /><br>').prependTo('#box');
};
});
});