Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <aura:attribute name="environmentType" type="String" description="This variable is used to indicate which environment this component is displayed on, f.i. community vs standard lightning" />
- <design:attribute name="environmentType" label="Environment Type" datasource="Community,Standard" required="true" description="Please indicate which environment this component is hosted on."/>
- var environment = component.get('v.environmentType');
- if (environment == 'Community') {
- // Do Community logic
- } else if (environment == 'Standard') {
- // Do Standard Lightning logic
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement