Note: This release is in preview. Features described here don’t become generally available until the latest general availability date that Salesforce announces for this release. Before then, and where features are noted as beta, pilot, or developer preview, we can’t guarantee general availability within any particular time frame or at all. Make your purchase decisions only on the basis of generally available products and features.

Setting Attributes Inherited from an Interface

To set the value of an attribute inherited from an interface, redefine the attribute in the component and set its default value. Let’s look at an example with the c:myIntf interface.

1<!--c:myIntf-->
2<aura:interface>
3    <aura:attribute name="myBoolean" type="Boolean" default="true" />
4</aura:interface>

This component implements the interface and sets myBoolean to false.

1<!--c:myIntfImpl-->
2<aura:component implements="c:myIntf">
3    <aura:attribute name="myBoolean" type="Boolean" default="false" />
4
5    <p>myBoolean: {!v.myBoolean}</p>
6</aura:component>