Enable configuration of components with inherited controllers in component builder
Learn how components can inherit page resources.
Using component builder, developers add data resources in two ways: directly within the component or through inheritance from the page.
Direct configuration
When you add data resources directly to a component, they remain contained within that component. These internal data resources are not visible or accessible when the component is placed on a page.
Inheritance
You can configure a component to inherit data resources from the page where it's placed. When inheritance is enabled, the component scans for data resources of the same type and automatically connects to them. For example, a component configured to inherit form controllers will look for form controllers on the page. This allows the component to be used across different page contexts and leverage existing data resources without manual configuration each time.
When you place a component configured for inheritance on a page, the inheritance behavior works as follows:
| Matching resources found | Behavior |
|---|---|
| No match found | Creates a new resource of the same type using the component's initial configuration |
| One | Connects to that resource |
| Multiple | Connects to the first instance of that resource |
Parent Topic:Component Builder
Enable configuration of components with inherited controllers
Configure components to automatically inherit controllers and data resources when placed on pages.
Before you begin
Role required: ui_builder_admin
About this task
In this Component Builder example, we will create a text component and configure it to inherit the List controller. We will then place it on an list page where the component connects to the List controller and displays the appropriate table name.
Procedure
Navigate to All > Now Experience Framework > UI Builder.
Select Create from the UI Builder home page.
UI Builder home page with the Create component button.
Select Component.
In the form, enter the following values:
Field Value Name Table ReferenceCategories Content Description Text component that displays the name of the current page's tableIcon (Default) Select Create.
Add a data resource to the component.
In the data resource drawer, select + Add data resource.
On the left, select List Controller.
On the right, select Advanced configurations to expand the section.
Select the Inherit configurations from parent option to enable the property.
Select Add.
Select a data resource modal with List controller selected and Inherit configurations from parent enabled.
Create the component.
In the content tree, select + Add content.
Select Single column, then select Add.
In the content tree, select + Add content under Column 1.
Select a Stylized text, then select Add.
Select Cancel to close the preset window.
Configure the component to use the List controller.
- In the configuration panel, hover over Text and select the bind data
icon.
2. On the left, select the **Formulas** tab, then double-click **CONCAT**.
3. In the upper section, double-click **value1** to edit the field and enter `"List showing records from "`.
4. Double-click **values** to edit the field and enter `@data.list_controller_1.tableLabel`.
5. Select **Apply**.
Select Save to save your work.
Your custom component is now available in the toolbox and ready for use in a page.
Place the component on a list page to see it automatically inherit the List controller and display the table name.
UI Builder editor showing custom component inheriting the list controller and displaying the table name.