Fix Dynamic Strikeout not Update during Add to Cart (Ajax) in Product page

Fix dynamic strike-through pricing update issue during Ajax Add to Cart on Product pages.

// Fix - Dynamic Strikeout not Update during Add to Cart (Ajax) in Product page
add_action('wp_footer', function () {
    if (function_exists('is_product') && is_product()) {
        ?>
            <script>
                jQuery(function($) { 
                    $(document.body).on('added_to_cart removed_from_cart wc_fragments_refreshed', function() {
                        $('[name="quantity"]').trigger('change');
                    });
                });
            </script>
        <?php
    }
});