Automattic\WooCommerce\Admin\Features\ProductBlockEditor\ProductTemplates
ProductFormTemplateInterface::get_block_by_id
Gets Block by id.
Method of the class: ProductFormTemplateInterface{}
No Hooks.
Returns
BlockInterface|null
.
Usage
$ProductFormTemplateInterface = new ProductFormTemplateInterface(); $ProductFormTemplateInterface->get_block_by_id( $block_id ): ?BlockInterface;
- $block_id(string) (required)
- block id.
ProductFormTemplateInterface::get_block_by_id() ProductFormTemplateInterface::get block by id code WC 9.9.5
public function get_block_by_id( string $block_id ): ?BlockInterface;