【发布时间】:2020-03-23 23:51:13
【问题描述】:
尝试使用代码进行动态加载:
var myComponentInstance = Builder.load({
path: "~/components/my-control",
name: "MyControl"
});
console.log(myComponentInstance);
return myComponentInstance;
得到一个错误:
错误:[object Object] 不是有效的 View 实例。
谁能帮我加载组件?请参阅下面的操场链接:
https://play.nativescript.org/?template=play-js&id=SoGnxo&v=18
【问题讨论】: