I have a custom validation rule (custom-firstname) in my rules.js file. In checkout_index_index I’ve set the firstname field to be validated in shipping address form - in the first checkout step that is. It looks like this:
<item name="firstname" xsi:type="array">
<item name="validation" xsi:type="array">
<item name="custom-firstname" xsi:type="string">true</item>
</item>
</item>
How to do the same in billing address - in the second checkout step where user can set up another address? I’m trying to put the billingAddress child to billing-step but it doesnt work.
<item name="billingAddress" xsi:type="array">
<item name="children" xsi:type="array">
<item name="billing-address-fieldset" xsi:type="array">
<item name="children" xsi:type="array">
<item name="firstname" xsi:type="array">
<item name="validation" xsi:type="array">
<item name="custom-firstname" xsi:type="string">true</item>
</item>
</item>
</item>
</item>
</item>
</item>