1

I am editing this file

RootFolder\vendor\magento\module-checkout\view\frontend\layout\checkout_index_index

To add new validations to the checkout.

For fields like telephone I just need to edit it like this:

<item name="telephone" xsi:type="array"> 
<item name="config" xsi:type="array"> 
<item name="tooltip" xsi:type="array"> 
<item name="description" xsi:type="string" translate="true">For delivery questions.</item> </item> </item> 

<!-- Validation starts --> 
<item name="validation" xsi:type="array"> 
<item name="validate-email" xsi:type="boolean">true</item> </item>
 <!-- Validation ends -->
 </item>

But I can't find where to add a validation to one of the address fields

enter image description here

Does somebody know how to add a validation to one of the address fields?

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Browse other questions tagged or ask your own question.