Monday, October 8, 2018

How to use angular application inside salesforce lightning component using lightning container

salesforce lightning,
Steps.

1. Develop your lighting app
2. ng build to create dist folder use ng build --prod --env=prod if you want a minified js file
3. now copy the contents of dist folder into a zip
4. Upload zip file as static resource and name it for example as angularapp

5. Inside your component add the following markup ,wherever you want to place the app.

           <lightning:container aura:id="AngularApp"     src="{!$Resource.angularapp1 + '/index.html'}"       />


6/ embed the component in an lighting app the test out the UI

How to deploy or host angular app in Github pages as a website




No comments:

Post a Comment