JSFiddle - React, Tailwind, and code Playground
HTML
<div id="myDiv">
<h2>Let AJAX change this text</h2>
</div>
<button type="button" onclick="myFunction();">Change Content</button>
JavaScript
function myFunction() {
$('#myDiv').load('/echo/js/?js=Success!')
}