A comma-separated list of interfaces that the component implements. An interface defines where Lightning Components are available. The following some of the available interfaces and their importance:
Interface | Description |
force:appHostable |
Creates a component for use as a navigation element in Lightning Experience or Salesforce mobile apps. |
forceCommunity:availableForAllPageTypes |
Creates a component that's available for drag and drop in the Community Builder. |
flexipage:availableForAllPageTypes |
Creates a component for use in Lightning pages or the Lightning App Builder. |
flexipage:availableForRecordHome |
Creates a component for use on a record Homepage in Lightning Experience. |
force:LightningQuickAction |
Creates a component that can be used with a Lightning quick action. |
Lightning:actionOverride |
Overrides a standard action in Lightning Experience. |
The syntax with multiple interfaces for the component is as follows:
<aura:component access="global" description="Youtube Search Component" implements="flexipage:availableForAllPageTypes,flexipage:availableForRecordHome,force:appHostable">
<!-- Optional coponent attributes here -->
<!-- Optional HTML markup -->
</aura:component>
In Chapter 1, Introduction to the Lightning Component Framework, we briefly touched upon the Lightning Design System. The Lightning Design System provides pre-defined patterns to build a UI without having to reinvent or code much. However, the Lightning Design System alone is not sufficient to attain a working application. That requires the developer to use JavaScript code to add client-side interactivity. Salesforce has simplified this by providing some out-of-the-box components with the Lightning namespace. Your goal, as a developer, should be to use these components as much as possible. They simplify the application build by having to code lots of JavaScript. However, note that, if you need functionality, that's not provided by out-of-the-box components; you could always custom code the entire markup.