Splunk Cloud Platform

Is it possible to embed the Angular app I have developed in Splunk enterprise?

nikupiku
Explorer

Hi,

I am very new to Splunk.
I am familiar with angular as we do all our projects in angular.

I would like to know if it is possible to embed the angular app I have developed in Splunk enterprise?

I have followed a similar tutorial for react and it works just fine.
https://github.com/robertsobolczyk/splunk-react-app

I was wondering if similar is possible for Angular 2+?

Any help would be highly appriciated.

Thanks

Labels (2)
Tags (1)
0 Karma

FNFI_Aniruddha
Observer

Found solution for angular 2+, Kindly reply back if you any.

0 Karma

nikupiku
Explorer

Great. Could you please share what you have found. I would like to see it.
Thanks

0 Karma

FNFI_Aniruddha
Observer

I did not found  and i am also looking for the solution.

0 Karma

kamlesh_vaghela
SplunkTrust
SplunkTrust

@nikupiku 

Yes, It is possible.. If you are good with React or Angular you can easily integrate it with splunk. Please check below my POC example .

XML

<dashboard script="a.js">
<label>Angular JS Integration</label>
<row>
  <panel>
    <html>
      <div ng-app="">
 
<p>Name: <input type="text" ng-model="name"/></p>
<p>You wrote: {{ name }}</p>

</div>
    </html>
  </panel>
</row>
</dashboard>

 

a.js

'use strict';

requirejs.config({

    baseUrl: '',

    paths: {
        'angular_kv': 'https://cdnjs.cloudflare.com/ajax/libs/angular.js/1.8.2/angular',
    },

    shim: {
        'angular_kv': {
            deps: ['jquery'],
            exports: 'angular_kv'
        },
    }
});

require([
    'jquery',
    'splunkjs/mvc',
    'angular_kv',
    'splunkjs/mvc/simplexml/ready!'
], function($, mvc, angular) {
    console.log('angular');

});

 

I hope this will help you.

Thanks
KV

If any of my reply helps you to solve the problem Or gain knowledge, an upvote would be appreciated.

0 Karma

nikupiku
Explorer

Hi @kamlesh_vaghela ,

Thank you for your reply, but looks like you are posting solution for angular js not angular 2+.

angular js and angular 2+ are different framework.


 

0 Karma

kamlesh_vaghela
SplunkTrust
SplunkTrust

Attaching screen.

Screenshot 2022-03-07 at 9.40.09 AM.png

 

You can add app and route as per your requirement.

KV

0 Karma
Get Updates on the Splunk Community!

CX Day is Coming!

Customer Experience (CX) Day is on October 7th!! We're so excited to bring back another day full of wonderful ...

Strengthen Your Future: A Look Back at Splunk 10 Innovations and .conf25 Highlights!

The Big One: Splunk 10 is Here!  The moment many of you have been waiting for has arrived! We are thrilled to ...

Now Offering the AI Assistant Usage Dashboard in Cloud Monitoring Console

Today, we’re excited to announce the release of a brand new AI assistant usage dashboard in Cloud Monitoring ...