You need to sign in to do that
Don't have an account?
Utility BarAPI on the doinit action has no recordId on the component
Hi,
I am using Utility BarAPI and I have the following component below openining when a button is clicked.
These Are the following implements on the Component
implements="flexipage:availableForAllPageTypes,force:hasRecordId"
To my understanding force:hasRecordId will give you the following variable (recordId) allowing you to know which contact your on.
When I run the code below recordId for some reason its null. I think its because doInit fires before the component is render so it has no recall of what recordId is. Since This component is hidden inside a utilitybar. Is there a way around this?
<aura:handler name="init" value="{!this}" action="{!c.doInit}" /> let contactId = component.get("v.recordId"); console.log(contactId) => null