JSFiddle - React, Tailwind, and code Playground
HTML
<form>
<input type='text'/>
</form>
CSS
article, aside, figure, footer, header, hgroup,
menu, nav, section { display: block; }
body {
font-family: sans-serif;
}
p {
margin: 0px;
}
JavaScript
jQuery(function($) {
$('form input[type=text]').change(fileChangeHandler);
function fileChangeHandler() {
var form = $(this).closest('form');
}
var form = $(this).closest('form');
$('form input').on("propertychange keyup input paste",
addInput);
function addInput() {
var remainingChars = $(this).val().length;
if (remainingChars == 24) {
$('<input type="text">').change(fileChangeHandler).appendTo('form').focus().on("propertychange keyup input paste",addInput);
}}
});