Activity Forums Salesforce® Discussions For what purpose Aura:if used in Salesforce Lightning Component?

  • Prachi

    Member
    July 27, 2018 at 7:34 am

    Hello Anjali,

    Use of aura:if:-

    Aura:if renders the content within the tag if the isTrue attribute evaluates to true.
    The framework evaluates the isTrue expression and instantiates components either in its body or else attribute. Also, aura:if instantiates the components in either its body or the else attribute, but not both.

    Thanks.

  • Parul

    Member
    September 23, 2018 at 8:58 am

    aura:if instantiates the components in either its body or the else attribute, but not both. aura:renderIf instantiates both the components in its body and the else attribute, but only renders one. If the state of isTrue changes, aura:if has to first instantiate the components for the other state and then render them. We recommend using aura:if instead of aura:renderIf to improve performance.

Log In to reply.

Popular Salesforce Blogs

Popular Salesforce Videos