Core Function
View Source on Trac ↗ register_block_pattern_category()
register_block_pattern_category( mixed $category_name, mixed $category_properties ) Registers a new pattern category.
Parameters 2 required
| Name / Type | Description |
|---|---|
| $category_name string | Pattern category name including namespace. Required |
| array | $category_properties List of properties for the block pattern. See WP_Block_Pattern_Categories_Registry::register() for accepted arguments. Required |
Return Value
(bool)
True if the pattern category was registered with success and false otherwise.
Function Information
Since Version
5.5.0
Source File
wp-includes/class-wp-block-pattern-categories-registry.php
Advertisement