In UI component form, input fields(text and text area) are working allright. But when i try to replace it with a label it gives an error.
Code:
<field name="name">
<argument name="data" xsi:type="array">
<item name="config" xsi:type="array">
<item name="label" xsi:type="string">Name</item>
<item name="visible" xsi:type="boolean">true</item>
<item name="dataType" xsi:type="string">text</item>
<item name="formElement" xsi:type="string">label</item>
</item>
</argument>
</field>
Error:
Exception #0 (Magento\Framework\Exception\LocalizedException): The requested component ("label") is not found. Before using, you must add the implementation.
I have researched a lot and couldn't find any worth mentioning solution.