View elements

Magento's primary view elements are its UI Components, containers, and blocks. The following is a brief overview of each of them.

Ui components

Under the vendor/magento/framework/View/Element/ folder, we can find UiComponentInterface and UiComponentFactory. The full set of Ui components is located under the vendor/magento/framework/View/Element/ directory. Magento implements UiComponent through a separate module called Magento_Ui. Thus, the components themselves are located under the vendor/magento/module-ui/Component/ directory.

Components implement UiComponentInterface, which is defined under the vendor/magento/framework/View/Element/UiComponentInterface.php file as follows:

namespace Magento\Framework\View\Element; use Magento\Framework\View\Element\UiComponent\ContextInterface; ...

Get Magento 2 Developer's Guide now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.