woocommerce-blocks

Customize WooCommerce block checkout with inner blocks, SlotFills, and Store API extensions.

3|1|Updated Mar 21, 2026
One-click install
npx skills add https://github.com/tomtoto757/ecomm-ai-team --skill woocommerce-blocks-tomtoto757
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: woocommerce-blocks
Source: https://github.com/tomtoto757/ecomm-ai-team/tree/main/skills/platform-integrations-infrastructure/finsilabs/platform-woocommerce/woocommerce-blocks
Command: npx skills add https://github.com/tomtoto757/ecomm-ai-team --skill woocommerce-blocks-tomtoto757

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill requires @wordpress/scripts, @wordpress/element, @wordpress/data, @wordpress/plugins, @woocommerce/blocks-checkout, @woocommerce/block-data.

What problem does it solve? WooCommerce's block-based cart and checkout cannot be customized with classic template overrides, so developers need the correct Gutenberg-era patterns to add custom fields, inject UI, and persist custom data to orders. ## Core Features & Use Cases - Checkout Inner Blocks: Register React components inside checkout steps using the IntegrationInterface, block.json, and registerCheckoutBlock. - SlotFill UI Injection: Inject banners and content into predefined checkout slots via registerPlugin with the woocommerce-checkout scope. - Store API Persistence: Extend the Cart schema, validate and sanitize data server-side, and transfer session data to order meta on checkout. - Use Case: A food retailer adds a delivery date picker to the shipping step, persists the selection through the Store API, and saves it to order meta for warehouse scheduling. ## Quick Start Use the woocommerce-blocks skill to add a gift message field to the block checkout and save it to order meta.

Frequently Asked Questions about woocommerce-blocks

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I add a custom field to WooCommerce block checkout?▼

Register an inner block by implementing the IntegrationInterface in PHP, defining a block.json with a woocommerce checkout step as parent, and calling registerCheckoutBlock from @woocommerce/blocks-checkout in JavaScript. Persist the value with extensionCartUpdate and a Store API update callback.

What is the difference between inner blocks and SlotFills in WooCommerce checkout?▼

Inner blocks are React components registered inside a specific checkout step via block.json, suited for form fields. SlotFills use registerPlugin with scope woocommerce-checkout to inject content into predefined slots like ExperimentalOrderMeta, which is simpler for banners and notices.

Why is my WooCommerce extension data not saving to the order?▼

Store API session data is not automatically copied to orders. You must hook woocommerce_checkout_order_created and transfer the session value to the order with $order->update_meta_data() and $order->save().

Can I validate checkout fields client-side with registerCheckoutFilters?▼

Client-side filters can modify display values and block checkout with error messages, but they can be bypassed. Always re-validate extension data server-side in the woocommerce_store_api_register_update_callback and throw a RouteException on invalid input.

Why is my SlotFill component not rendering in the checkout block?▼

The registerPlugin call must include scope set to the exact string woocommerce-checkout; omitting it or using the wrong scope silently prevents rendering. Also verify the SlotFill component is imported from @woocommerce/blocks-checkout.