JSFiddle - React, Tailwind, and code Playground

HTML

<p>0</p>

JavaScript

$("p").click(function(){
     $(this).html(parseInt($(this).html())+1);
  });