Automattic\WooCommerce\Blocks\Utils

BlockTemplateUtils::get_block_template_description()public staticWC 1.0

Returns template description.

Method of the class: BlockTemplateUtils{}

No Hooks.

Return

String. Template description.

Usage

$result = BlockTemplateUtils::get_block_template_description( $template_slug );
$template_slug(string) (required)
The template slug (e.g. single-product).

BlockTemplateUtils::get_block_template_description() code WC 9.4.2

public static function get_block_template_description( $template_slug ) {
	$registered_template = self::get_template( $template_slug );
	if ( isset( $registered_template ) ) {
		return $registered_template->get_template_description();
	}
	return '';
}