Sunday, 26 August 2018

Interface Reference of Lightning


Implement these platform interfaces to allow a component to be used in different contexts, or to enable your component to receive extra context data. A component can implement multiple interfaces. Some interfaces are intended to be implemented together, while others are mutually exclusive. Some interfaces have an effect only in Lightning Experience and the Salesforce app.

Interfaces belong to different namespaces, including:

clients
Provides interfaces that are specific to Lightning for Outlook or Lightning for Gmail.
flexipage
Provides interfaces that are specific to Lightning Pages and the Lightning App Builder.
force
Provides interfaces that are specific to Lightning Experience and the Salesforce app.
forceCommunity
Provides interfaces that are specific to Communities.
lightning
Provides interfaces that are specific to Lightning Experience, the Salesforce app, and Communities.
ltng
Provides events that are handled by Lightning Out.
Some of these interfaces are summarized below. For a complete list, refer to the Component Library.

clients:availableForMailAppAppPage
To appear in the Lightning App Builder or a Lightning Page in Lightning for Outlook or Lightning for Gmail, a component must implement the clients:availableForMailAppAppPage interface. 
clients:hasEventContext
Enables a component to be assigned to an event’s date or location attributes in Lightning for Outlook and Lightning for Gmail. 
clients:hasItemContext
Enables a component to be assigned to an email’s or a calendar event’s item attributes in Lightning for Outlook and Lightning for Gmail.
flexipage:availableForAllPageTypes
A global interface that makes a component available in the Lightning App Builder, and for any type of Lightning page.
flexipage:availableForRecordHome
If your component is designed only for record pages, implement the flexipage:availableForRecordHome interface instead of flexipage:availableForAllPageTypes
forceCommunity:availableForAllPageTypes
To appear in Community Builder, a component must implement the forceCommunity:availableForAllPageTypes interface. 
force:appHostable
Allows a component to be used as a custom tab in Lightning Experience or the Salesforce app. 
force:lightningQuickAction
Allows a component to display in a panel with standard action controls, such as a Cancel button. These components can also display and implement their own controls, but should handle events from the standard controls. If you implement force:lightningQuickAction, you can’t implement force:lightningQuickActionWithoutHeader within the same component.
force:lightningQuickActionWithoutHeader
Allows a component to display in a panel without additional controls. The component should provide a complete user interface for the action. If you implement force:lightningQuickActionWithoutHeader, you can’t implement force:lightningQuickAction within the same component. 
ltng:allowGuestAccess
Add the ltng:allowGuestAccess interface to your Lightning Out dependency app to make it available to users without requiring them to authenticate with Salesforce. This interface lets you build your app with Lightning components, and deploy it anywhere and to anyone. 

References:
https://developer.salesforce.com/docs/component-library/overview/interfaces
https://developer.salesforce.com/docs/atlas.en-us.lightning.meta/lightning/ref_interfaces.htm


No comments:

Post a Comment

What’s the difference between Einstein Article Recommendations and Suggested Articles?

How Does Einstein Article Recommendations Work? Einstein Article Recommendations helps support agents resolve customer cases efficiently by ...