Activity Forums Salesforce® Discussions How can we use lightning component in salesforce community

  • How can we use lightning component in salesforce community

  • Vikas Kumar

    Member
    February 15, 2017 at 2:33 pm

    Hi all,

    How can we use lightning component in salesforce community ?

    Thanks

  • Kumar

    Member
    February 16, 2017 at 2:10 pm

    Hi Vikas,

    In order to be used in a community, your lightning component must implement the "forceCommunity:availableForAllPageTypes" interface and its access must be "global".

    Something like this:

    <aura:component implements="forceCommunity:availableForAllPageTypes" access="global">
    <aura:attribute name="greeting" type="String" default="Hello" access="global" />
    <aura:attribute name="subject" type="String" default="World" access="global" />

    <div style="box">
    <span class="greeting">{!v.greeting}</span>, {!v.subject}!
    </div>
    </aura:component>

Viewing 1 - 2 of 2 posts

Log In to reply.

Popular Salesforce Blogs

Popular Salesforce Videos