2

I've have a component that implements force:lightningQuickAction but would like to have conditional rendering (i.e only display on the page layout if a bool field == true). I've been researching, but have not found a way to conditionally render within a standard component? Does anyone know if this is possible, or if a parent component is the only way to do this?

0

If the challenge is to conditionally show a component on a page layout based on a field value, you can do it starting winter 18 using "set component visibility" in your app builder.

https://releasenotes.docs.salesforce.com/en-us/winter18/release-notes/rn_forcecom_lab_dynamic_pages.htm

| improve this answer | |
  • I understand that you can conditionally render a component in the new release, but if you would like the component to display as a quick action is there a way to conditionally display the action within the component without hiding the entire component without creating a parent component? – Starley Flynn Nov 1 '17 at 22:52
  • Assuming you have control over the component, why not call the quickactionclose event when the user clicks the button based on the user profiles you want to restrict ??? – Rao Nov 2 '17 at 1:01

Not the answer you're looking for? Browse other questions tagged or ask your own question.