Dashboards & Visualizations

Can we use our own costume javascript except form setup.xml?

amolp07
New Member

I want to use my own written java script except form setup.xml in Technology Add-on(Moduler Input).
I want to update setup.xml dynamically.
Is this possible?
please late me know if is there any way to achieve this? or alternative way

Thanks in advance.

0 Karma
1 Solution

kamlesh_vaghela
SplunkTrust
SplunkTrust

@amolp07

You can create YOUR_APP/appserver/static/application.js and write your logic in this file. But you have to take care in your javascript logic development style.

application.js is automatically called in setup.xml so no need to include. But as there is auto-inclusion of application.js we have to take care that your logic in javascript, like executing code only if some element found on page load. Just try and let me know if any issue.

Thanks

View solution in original post

0 Karma

kamlesh_vaghela
SplunkTrust
SplunkTrust

@amolp07

You can create YOUR_APP/appserver/static/application.js and write your logic in this file. But you have to take care in your javascript logic development style.

application.js is automatically called in setup.xml so no need to include. But as there is auto-inclusion of application.js we have to take care that your logic in javascript, like executing code only if some element found on page load. Just try and let me know if any issue.

Thanks

0 Karma
Get Updates on the Splunk Community!

Introducing the 2024 SplunkTrust!

Hello, Splunk Community! We are beyond thrilled to announce our newest group of SplunkTrust members!  The ...

Introducing the 2024 Splunk MVPs!

We are excited to announce the 2024 cohort of the Splunk MVP program. Splunk MVPs are passionate members of ...

Splunk Custom Visualizations App End of Life

The Splunk Custom Visualizations apps End of Life for SimpleXML will reach end of support on Dec 21, 2024, ...