Loading
Prepare for Email to Become the Default Login ExperienceRead More
Intermittent freezing when using using certain browser versionsRead More
Automate Your Business Processes with Salesforce Flow
Embed a Flow in a Custom Aura Component

Embed a Flow in a Custom Aura Component

To customize how your flow gets and receives data, add it to a custom Aura component. Then distribute that component through a custom action, Lightning tab, or Lightning page.

Required Editions

To embed a flow in your Aura component, add the lightning:flow component to it, for example:

<aura:component>
  <aura:handler name="init" value="{!this}" action="{!c.init}" /> 
  <lightning:flow aura:id="flowData" />
</aura:component>

In the JavaScript controller, identify which flow to start, for example:

({ 
  init : function (component) { 
    // Find the component whose aura:id is "flowData" 
    const flow = component.find("flowData"); 
    // In that component, start your flow. Reference the flow's API Name. 
    flow.startFlow("myFlow");
  },
})
 
Loading
Salesforce Help | Article