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
Ramk123Ramk123 

How make different Audience permissions in the Community builder

Dear Experts,

In my community, I have one Custom Lightning component and Rich Text Editor, but I would like to Restrict the lightning component visibility to the Guest Users. When I apply "Assign Audience" it is applicable to both the "Custom lightning Component" and "Rich Text Editor". Kindly advice.
Best Answer chosen by Ramk123
AbhishekAbhishek (Salesforce Developers) 
Each Component can only have one audience. 

If for example, you want the Rich Text to always display then you don't need to assign an audience to it. 

If for example, you want the Lightning Component to only display for Guest Users then you need to create an Audience based on Profile and then assign the audience to the Component. 

If you want a component to be displayed for Guest Users and logged-in users in the USA then you'd need to create a custom audience for this where User Profile = Guest Users or Location = USA for example. 


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.

All Answers

AbhishekAbhishek (Salesforce Developers) 
Each Component can only have one audience. 

If for example, you want the Rich Text to always display then you don't need to assign an audience to it. 

If for example, you want the Lightning Component to only display for Guest Users then you need to create an Audience based on Profile and then assign the audience to the Component. 

If you want a component to be displayed for Guest Users and logged-in users in the USA then you'd need to create a custom audience for this where User Profile = Guest Users or Location = USA for example. 


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.
This was selected as the best answer
Ramk123Ramk123

Thanks, Abhishek!

Just to recap what I did to make it work in my scenario

Audience 1 

Component 1: I made a Custom Lightning Component Visible only to Authenticated User Profile ( Profile = XXX)

Audience 2

Component 2: I made a Rich Content Editor Visible does not equal to Authenticated User Profile( Profile NE XXX)