Activity Forums Salesforce® Discussions How can we use a lightning component in a Salesforce VisualForce Page?

  • shariq

    Member
    September 23, 2018 at 10:45 pm

    A Lightning component can be embed in any webpage using a very powerful and flexible feature, Lighting out. When used with Visualforce some complexity becomes simpler.
    Lightning component can be added to Visualforce page in three steps:

    1. We have to first Add the Lightning Components for Visualforce JavaScript library to your targetted Visualforce page using the tag.

    2. Next we have to create and refer a Lightning app which is used to the component dependencies.

    3. Lastly we need to write a JavaScript function which will finally create the the component on the page using $Lightning.createComponent()

  • Avnish Yadav

    Member
    September 30, 2018 at 3:47 am

    Hello,

    There are three steps to add Lightning components to a Visualforce page.

    1. Add the Lightning Components for Visualforce JavaScript library to your Visualforce page using the <apex:includeLightning/> component.
    2. Create and reference a Lightning app that declares your component dependencies.
    3. Write a JavaScript function that creates the component on the page using $Lightning.createComponent().

    Thanks.

  • Avnish Yadav

    Member
    September 30, 2018 at 3:47 am

    Lightning Components for Visualforce is based on Lightning Out, a powerful and flexible feature that lets you embed Lightning components into almost any web page. When used with Visualforce, some of the details become simpler. For example, you don’t need to deal with authentication, and you don’t need to configure a Connected App.

    In other ways using Lightning Components for Visualforce is just like using Lightning Out. Refer to the Lightning Out section of this guide for additional details

Log In to reply.

Popular Salesforce Blogs

Popular Salesforce Videos