Automattic\WooCommerce\Blocks\Templates
ProductTagTemplate::render_block_template
Run template-specific logic when the query matches this template.
Method of the class: ProductTagTemplate{}
No Hooks.
Returns
null. Nothing (null).
Usage
$ProductTagTemplate = new ProductTagTemplate(); $ProductTagTemplate->render_block_template();
ProductTagTemplate::render_block_template() ProductTagTemplate::render block template code WC 11.1.2
public function render_block_template() {
if ( ! is_embed() && is_product_taxonomy() && is_tax( 'product_tag' ) ) {
$compatibility_layer = new ArchiveProductTemplatesCompatibility();
$compatibility_layer->init();
add_filter( 'woocommerce_has_block_template', '__return_true', 10, 0 );
}
}