I have posted few articles on Lightning Out. In this post, we will see how Lightning components can be displayed on public website. To access these Lightning components, users don’t need to login to Salesforce.
For this post, I will consider Text slider component created in this post. Using this same method, I have displayed Live demo of Lightning component on wordpress blog.
What do you need :
Option 1 [Used in this blog post] :
- Public Site or Public Community Page
- Visualforce wrapping Lightning App marked as Lightning out
- This website – https://JitendraZaa.com added in Salesforce CORS setting, so that Salesforce can be added as iframe in this website
- Embed public site as iframe
Option 2 :
- Follow this documentation
- Import Lightning Out Javascript Library in your website using Community URL
- Use JavaScript SDK to create Lightning application dynamically
Live Demo using Public Site and Visualforce :