WooCommerce make checkout field mandatory if
<p>I've created several new checkout fields for my checkout page.<br>
One field is the first radio button with <em>"type klant"</em> this lets the user choose between customer type (business or private). When either is selected, some fields are hidden/shown by me with Javascript.</p>

<p>The <em>"bedrijfsnaam"</em> (business name) field is shown when <em>"bedrijf"</em> (business) is selected, it is not required. If made required and the user selects <em>"particulier"</em> (private) the field is not hidden with js, but present html-wise, so when completing, the validation gives an error to enter the business name. </p>

<p>How can I change the validation to only check the business name field when business is selected in customer type?</p>

<p>I probably have to do something with the <code>do_action( 'woocommerce_before_checkout_process' );</code> to make the required check based on the radio button, but I got stuck there, any clues?</p>

<p>Thanks!</p>