wp_enable_block_templates()
This function’s access is marked private. This means it is not intended for use by plugin or theme developers, only in other core functions. It is listed here for completeness.
Enable the block templates (editor mode) for themes with theme.json by default.
Source
File: wp-includes/theme-templates.php
function wp_enable_block_templates() { if ( WP_Theme_JSON_Resolver::theme_has_support() ) { add_theme_support( 'block-templates' ); } }
Changelog
Version | Description |
---|---|
5.8.0 | Introduced. |
© 2003–2021 WordPress Foundation
Licensed under the GNU GPLv2+ License.
https://developer.wordpress.org/reference/functions/wp_enable_block_templates