Hello,
I need help with my code. I am importing components from the team library. When I call the import function, I get back a JS promise. I don’t know how to work with this promise. I need to change the text and variants of components in this imported component.
My code:
async function importNode() {
let importComponent = await Figma.importComponentByKeyAsync(“5cad1f5ace96bf648”);
const favC = importComponent.findOne(node => node.type == “COMPONENT” && node.name == “Favorite”) as ComponentNode;
return favC;
}
How can I access the imported component and browse it and use the embedded components?
Thanks