Find sub-compositions and widgets
Functions covered
Composition structure
Composition scripts
Last updated
Last updated
(function() {
return {
init: function(comp, context) {
// get reference to the subcomposition "Lower"
const compLower = comp.find("Lower")[0];
// log composition object to the console
console.log(compLower);
},
close: function(comp, context) {}
};
})();(function() {
return {
init: function(comp, context) {
// get reference to the title, subtitle, and logo widget
const wiLowerTitle = comp.findWidget("lowerTitle")[0];
const wiLowerSubtitle = comp.findWidget("lowerSubtitle")[0];
const wiLowerLogo = comp.findWidget("lowerLogo")[0];
// log widget objects to the console
console.log(wiLowerTitle);
console.log(wiLowerSubtitle);
console.log(wiLowerLogo);
},
close: function(comp, context) {}
};
})();