JSFiddle - React, Tailwind, and code Playground

by Nicolas PUJOL

HTML

<div id="get10">
    Give me 10£
</div>

JavaScript

var total = 0;
function get10() {
    total += 10;
    console.log("+10 €", "total: " + total);
    init10();
}

function init10() {
    $('#get10').on('click', function() {
        get10();
    });
}
init10();