Converting exisitng checkout custom code to app using Checkout UI Extensions

We are looking to move to Checkout Extensibility upgrade. Currently we have 2 features custom coded into the checkout which I believe when upgraded will need to be added as apps via Checkout UI Extensions.

Can anyone advise ‘exactly’ how to do this?

Details as follows -

Feature 1 - reduce characters in checkout shipping fields to max 35.

This is currently powered by the custom snippet in checkout-custom.liquid file

$(‘#checkout_shipping_address_address1, #checkout_billing_address_address1’).attr(‘maxlength’, 35);
$(‘#checkout_shipping_address_address1, #checkout_billing_address_address1’).on(‘input propertychange’, function() {
if ($(this).val().length > 35) {
$(input).val($(input).val().substring(0, 35));
}
});

Feature 2 - Show c’ompare at prices’ in checkout.
This is currently powered by the custom snippet in checkout-custom.liquid file

Still looking into the best way to do this - in particular reducing characters in shipping fields to 35.

Seems there are 3 options

  1. Do via Shopify functions

  2. Do via Extensions UI

  3. Use a third party adress validator.

Looking for direction on what would be the best option long term?