Automattic\WooCommerce\Blocks\Payments
Api::get_cart_checkout_script_handles
Get Cart and Checkout script handles for the active editor asset configuration.
Method of the class: Api{}
No Hooks.
Returns
string[]. Script handles.
Usage
// private - for code of main (parent) class only $result = $this->get_cart_checkout_script_handles(): array;
Api::get_cart_checkout_script_handles() Api::get cart checkout script handles code WC 11.1.2
private function get_cart_checkout_script_handles(): array {
$editor_handles = BlockEditorUnifiedAssets::is_enabled()
? array( 'wc-block-library' )
: array( 'wc-checkout-block', 'wc-cart-block' );
return array_merge(
$editor_handles,
array( 'wc-cart-block-frontend', 'wc-checkout-block-frontend' )
);
}