I would like to run an externally hosted script in my SAC Analytic Application.
I know this is how it can be done in regular JavaScript:
function loadExternalScript() {
var script = document.createElement('script');
script.src = '/path/to/my/script.js';
var head = document.getElementsByTagName("head")[0];
head.appendChild(script);
}
Is there a way of doing the same thing in SAP's JavaScript-based language?
Eventually I used a custom widget as a workaround.
This is (more or less) my widget's main component:
And this is the json file I use to upload the widget to SAC environment: