JSFiddle - React, Tailwind, and code Playground

by Gene Arnold

HTML

<!DOCTYPE html>
<script type='text/javascript' src="http://localhost:8080/jasperserver-pro56_Beta/client/visualize.js"></script>
<body>
    <div id="container">
    </div>
</body>

JavaScript

visualize({
    auth: {
        name: "jasperadmin",
        password: "jasperadmin",
        organization: "organization_1"
    }
	}, function (v) {

    //render report from provided resource
    v("#container").report({
        resource: "/public/Samples/Reports/01._Geographic_Results_by_Segment_Report",
        error: handleError
    });
    
    //show error
    function handleError(err){
        alert(err.message);
    }
});