JSFiddle - React, Tailwind, and code Playground
HTML
<div id="data">
</div>
<button>getData()</button<
JavaScript
function getData() {
$.ajax({
url: "http://echo.jsontest.com/key/value/one/two",
dataType: "json"
}).success(function(data){
$('#data').append(JSON.stringify(data));
});
return false;
}
$('button').click(getData);