The Problem
I rebuilt a client's shop archive last week using the WooCommerce Product Collection block, the newer one that replaces the legacy Products (Beta) block. Looked great in the editor. On the live site, the Add to Cart button rendered fine but clicking it did absolutely nothing. No spinner, no mini cart update, no network request in DevTools. Just a dead button.
The same product added to cart fine from the single product page. The classic shortcode [products] worked. Cart fragments were refreshing on other pages. The only place broken was the Product Collection block.
The clincher: this client had been on WooCommerce 10.7 and the block was working until they bumped to 10.8 a couple of days earlier. Same theme, same plugins, same product data. So it had to be a block-side regression.
Why It Happens
The Product Collection block doesn't ship its own Add to Cart click handler. It renders the standard wc-block-components-product-button markup, and the click is supposed to be picked up by the global Interactivity API store that ships with @wordpress/interactivity and the Woo Blocks runtime. In WC 10.8 the store namespace for that handler moved from woocommerce/product-button to woocommerce/product-collection for Collection block contexts, and they stopped registering the legacy alias for blocks rendered server-side from the core/post-template inner loop.
If your theme (or a child theme) deregisters or replaces the @woocommerce/block-library script handle for performance, which a lot of speed-focused themes still do, the new namespace never gets registered. The button HTML is there, the data-wp-on--click attribute is there, but no store is listening. The click happens, the directive fires, the dispatcher looks up a namespace that doesn't exist, and you get silent failure. There is no console error because the Interactivity runtime swallows missing-namespace dispatches by design.
You can confirm it in 10 seconds. Open DevTools on the shop page and run:
window.wp.interactivity.getServerState();
If state['woocommerce/product-collection'] is missing or has no cart key, your store didn't register. That is the bug.
The WooCommerce Blocks store API reference lists what's expected here but doesn't yet flag the 10.8 namespace change. I had to dig through the woocommerce/woocommerce-blocks GitHub repo to confirm.
The Fix
There are three ways to handle this depending on what's causing the script to drop. Pick the one that matches your setup.
Step 1: Stop deregistering the Woo Blocks script. If your theme has something like this in functions.php, that is your culprit:
// Don't do this on a Product Collection page.
add_action('wp_enqueue_scripts', function () {
wp_deregister_script('wc-blocks-frontend');
wp_deregister_script('wc-blocks-registry');
}, 100);
Either remove it or scope it to pages that don't render the Product Collection block:
add_action('wp_enqueue_scripts', function () {
if (has_block('woocommerce/product-collection')) {
return;
}
if (is_shop() || is_product_category() || is_product_tag()) {
return;
}
wp_deregister_script('wc-blocks-frontend');
}, 100);
has_block() works on singular pages. For shop archives that don't have a post object, the is_shop() family of checks is what you want.
Step 2: Force the Interactivity store to register. If you can't remove the deregister (some optimization plugins do it via UI settings the client controls), you can re-register the missing namespace from a small mu-plugin:
add_action('wp_enqueue_scripts', function () {
if (! function_exists('wp_register_script_module')) {
return;
}
wp_register_script_module(
'@woocommerce/product-collection',
plugins_url(
'assets/client/blocks/product-collection-frontend.js',
WC_PLUGIN_FILE
),
['@wordpress/interactivity'],
WC_VERSION
);
wp_enqueue_script_module('@woocommerce/product-collection');
}, 20);
This re-points the module loader at the file Woo Blocks ships, regardless of what the theme deregistered. After deploying, the state['woocommerce/product-collection'] key should appear when you run the DevTools check again.
Step 3: Verify the click handler is wired. With the page loaded, inspect the Add to Cart button. The element should have these two attributes:
<button
data-wp-on--click="woocommerce/product-collection::actions.addToCart"
data-wp-bind--disabled="state.isPending"
>
Add to cart
</button>
If the data-wp-on--click attribute is missing entirely, you are on the older core/post-template render path and you need to resave the block in the editor so it re-renders with the new directives. The block markup changed in WC 10.8 and old saved copies still use the dead onclick form.
After the fix went in for my client, click-through-to-cart went from 0% to baseline on the shop archive and the mini cart fragment started refreshing again on the first click. No theme rebuild, just two small changes.
The Lesson
The Product Collection block is the new default in the editor and it depends on the Interactivity API runtime that ships as a script module, not a classic enqueue. Any "performance" plugin or theme tweak that deregisters Woo Blocks scripts will silently break Add to Cart on Collection blocks under WC 10.8+. If you are migrating off legacy [products] shortcodes or the old Products (Beta) block, audit your wp_deregister_script calls first.
If your store's shop archive button is dead after a WooCommerce update and you are not sure where to start, that is one of the audits I do for clients. See my services. For a related Woo Blocks gotcha on the cart page, read WooCommerce cart block quantity stepper not working on mobile.
Shop archive button dead after a Woo update? Let me fix it.
