_register_theme_block_patterns
- %1$s is private and should not be used in themes or plugins directly.
_register_theme_block_patterns ( No parameters )
Access:Defined at:Change Log: - Introduced in WordPress: 6.0.0
- Deprecated in WordPress: —
Description
Register any patterns that the active theme may provide under its
`./patterns/` directory. Each pattern is defined as a PHP file and defines
its metadata using plugin-style headers. The minimum required definition is:/**
* Title: My Pattern
* Slug: my-theme/my-pattern
*
The output of the PHP source corresponds to the content of the pattern, e.g.:
If applicable, this will collect from both parent and child theme.
Other settable fields include:
- Description
- Viewport Width
- Inserter (yes/no)
- Categories (comma-separated values)
- Keywords (comma-separated values)
- Block Types (comma-separated values)
- Post Types (comma-separated values)
- Template Types (comma-separated values)