Skip to content

Event Handler For When a Variant Is Changed#


Attribute Machine has a built in function you can implement which will allow you to call your own custom JS any time a product variant is changed. This is useful if you needed to load your own custom data based on an attribute/variant selection.


MivaEvents.SubscribeToEvent("variant_changed", function (product_data) {
    // call your update or refresh here