Using UI Editor Components from Code

When a component is created from UI Editor via drag & drop, it updates the generated file located at scripts/ui folder. In order to reduce side effects that caused by the code as much as possible, these components are not accessible directly from the code.

Component will be accessible under page in the code when assignToPage property is set from properties panel.

JavaScript
JavaScript
// onShow method of a Page
function onShow(superOnShow) {
const page = this;
page.myComponent; // Get myComponent under page
}

Default value of assignToPage is false