[英]How to use visualforce page with lightning:container React in Lightning app builder?
[英]Is It possible to use Lightning app exchange components in custom lightning app?
我从应用程序交换安装了一个闪电组件,现在我想在我的自定义闪电应用程序中使用该组件
可能吗??
<aura:app>
//code for adding components
</aura:app>
如果您正在使用组件:
<aura:component >
<aura:handler name="init" value="{!this}" action="{!c.doInit}"/>
{!v.body}
</aura:component>
并在控制器中(例如,“ mvc:CalendarComponent”,将您的组件放在此处):
doInit : function(component, event, helper) {
$A.createComponent(
"mvc:CalendarComponent",
{
},
function(newCmp){
if (component.isValid()) {
component.set("v.body", newCmp);
}
}
);
}
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.