This is a beta release of documentation for Magento 2.4, published for previewing soon-to-be-released functionality. Content in this version is subject to change. Links to the v2.4 code base may not properly resolve until the code is officially released.

Hidden component

The Hidden component is a form element that implements the HTML <input type="hidden"> field.

Configuration options

Option Description Type Default
component The path to the component’s JS constructor in terms of RequireJS. String Magento_Ui/js/form/element/abstract
template The path to the component’s .html template. String ui/form/element/hidden

Source files

Extends UiElement:

Examples

Integrate the Hidden component with the Form component

This example integrates the Hidden component with the Form component.

1
2
3
4
5
6
7
8
9
10
11
<form>
    ...
    <fieldset>
        ...
        <hidden name="hidden_example">
            <settings>
                <value>hidden value</value>
            </settings>
        </hidden>
    </fieldset>
</form>

Result

Hidden Component example