Add datepicker field to ui component form magento 2.

You can add a date picker to ui_component form component.

Field with date picker, you need to add field form element type is a date.

<field name=”birthday” formElement=”date”>

Code Snippet to add for a ui_component form.xml file,

<field name="birthday" formElement="date">
    <argument name="data" xsi:type="array">
        <item name="config" xsi:type="array">
            <item name="source" xsi:type="string">customer</item>
        </item>
    </argument>
    <settings>
        <validation>
            <rule name="validate-date" xsi:type="boolean">true</rule>
        </validation>
        <dataType>text</dataType>
        <visible>true</visible>
    </settings>
</field>

You can validate a date by adding a rule to <settings> tab with,

<validation>
    <rule name="validate-date" xsi:type="boolean">true</rule>
</validation>

Using the above code snippet, you can able to add date-picker in UI component form.