function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
chinna r 5chinna r 5 

Can we display a component conditionally in a Lightning Record Page in Aura?

Can we do that in Aura? also what are out-of-box events and system events in Aura? Can anyone explain these two questions?
ANUTEJANUTEJ (Salesforce Developers) 
Hi Chinna,

>> https://www.salesforceben.com/dynamically-showhide-lightning-components/

The above link dynamically-showhide-lightning-components.

In the lightning component, there are two types of events application and component event.

Component event is used to communicate from child component to parent component and application event works like a broadcast message for sending data to multiple components.

Let me know if it helps you and close your query by marking it as solved so that it can help others in the future.  

Thanks.
AnudeepAnudeep (Salesforce Developers) 
You can try something like this
<!-- Component Markup -->
<div aura:id="yourIdentifier">
    <c:Your_Component />
</div>

/**
 * Controller Method
 */
showComponent : function (component, event, helper) {
  $A.util.removeClass(component.find("yourIdentifier"), "slds-hide");
},
hideComponent : function (component, event, helper) {
  $A.util.addClass(component.find("yourIdentifier"), "slds-hide");
}
Or you can simplify using the following
toggleComponent : function (component, event, helper) {
	$A.util.toggleClass(component.find("yourIdentifier"), "slds-hide");
}

You can learn about system events here and standard events here

Let me know if this helps, if it does, please mark this answer as best so that others facing the same issue will find this information useful. Thank you