JSFiddle - React, Tailwind, and code Playground
by Kishoreajey
HTML
<script type='text/javascript' src="https://code.jquery.com/jquery-2.1.0.js"></script>
<script type="text/javascript">
var JSLink = $("https://spotfire.healthcareit.net").val();
var JSElement = document.createElement('script');
JSElement.src =JSLink + "/spotfire/wp/GetJavaScriptApi.ashx?Version=7.5";
document.getElementsByTagName('head')[0].appendChild(JSElement);
</script>
<button id="button">View Report</button>
<!--Provide container to render your visualization-->
<br><br>
<div id="demoViz" style="display:none;width:1580px;height:742px">Loading...</div>
JavaScript
window.onload = createReport("/Data Products & Services/Dashboards/IHP_BI/Spotfire Dashboard Details/BI Hub User Metrics-V1");
function createReport(reportPath) {
var c_serverUrl = JSLink + "/spotfire/wp";
//var c_serverUrl = "https://spotfire-dev.healthcareit.net/spotfire/wp";
var c_analysisPath = reportPath;
var c_parameters = ""; //Optional configuration block
var customization = new spotfire.webPlayer.Customization(); //Optional configuration settings
var app;
var c_reloadAnalysisInstance = false;
app = new spotfire.webPlayer.Application(c_serverUrl, customization, c_analysisPath, c_parameters, c_reloadAnalysisInstance);
//Hide UI elements
customization.showDodPanel = true;
customization.showStatusBar = true;
customization.showToolBar = true;
customization.showPageNavigation = true;
customization.showClose = true;
customization.showAnalysisInfo = true;
customization.showExportFile = true;
customization.showExportVisualization = true;
customization.showUndoRedo = true;
customization.showFilterPanel = true;
var viewOne = app.openDocument("demoViz", "Overview", customization);
}
);