JSFiddle - React, Tailwind, and code Playground

HTML

<form id="form" onsubmit="return false;" method>
    <input type="text" id="account" />
    <input type="text" id="url" />
    <input type="text" id="url" />
    <input type="button" onclick="genorateCode();" value="Click"/>
</form>

<div id="code"></div>

JavaScript

var account, url;

  function genorateCode() {
      account = document.getElementById("account").value;
      url = document.getElementById("url").value;
      sendCode();
  }

  function sendCode() {
      var str = '<a href="' + url + '">' + '<div class="button"><img src="https://s15.postimg.org/mfpd2ki8r/icon.png" width="16">@' + account + '</div></a>';
      document.getElementById('code').insertAdjacentHTML('beforeend', str);
  }