JSFiddle - React, Tailwind, and code Playground
HTML
<button id="btn">pew</button>
<pre id="out"></pre>
JavaScript
const iterator = (function*(n){while(true)yield n++;})(12);
btn.onclick = function() {
out.textContent += `Hello from here, ${iterator.next().value}\n`;
};