Skip to content

Magento 2: how to validate after shipping address change

During checkout I need to validate the shipping address and the current cart’s contents.
After the customer has entered or changed the shipping address a validation should start. Depending on a product attribute and the shipping location a message should appear on the screen telling the customer what’s going on.

Also the available shipping methods should be limited depending on the validation’s findings.

I know I need to hook into checkout_index_index.xml with a js component but don’t know at what point. I would need an equivalent to an event on the php level (e.g. “after_shipping_address” or something).

Any hint welcome.

Thank you