Here is component I want to navigate to, named TestCmp:
<aura:component implements="lightning:isUrlAddressable" access="global">
<aura:attribute name="someId" type="Id" />
{!v.someId}
</aura:component>
And here is code of component, from which I want to havigate:
<lightning:navigation aura:id="navService"/>
component.find("navService").navigate({
type: "standard__component",
attributes: { componentName: "c:TestCmp" },
state: { someId: "xx" }
});
When I press the button (this code is executed) nothing happens. No error message, nothing in console. Neither in community builder nor for community user. What I also find that in this code 'finally' is never executed:
component.find("navService").generateUrl({
type: "standard__recordPage",
"attributes": {
"recordId": accountId,
"objectApiName": "Account",
"actionName": "view"
}
}).finally(function(value) {
console.log(value);
});
If I log result of generateUrl function, it says Promise object with state 'pending'
Any ideas?