JSFiddle - React, Tailwind, and code Playground

by BramVanroy

HTML

<label for="source_post">
<input type="text" id="source_post" name="source_post" value="" style="width: 80%;max-width: 720px;"> Source of your post
</label><br>
    <button class="add-field">+</button>
<p>Try to be as specific as possible. <br> E.g. <em>http://tweakers.net/nieuws/101372/ing-belgie-wil-betalingsgedrag-van-klanten-meer-gebruiken-voor-dienstverlening.html</em></p>

JavaScript

counter = 0;
$(".add-field").click(function() {
    counter++;
    $("#source_post").after('<input type="text" id="source_post_'+counter+'" name="source_post_'+counter+'" value="" style="width: 80%;max-width: 720px;">');
});