Alert: 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.
wp_enable_block_templates()
Enables the block templates (editor mode) for themes with theme.json by default.
Contents
Source
File: wp-includes/theme-templates.php
.
View all references
function wp_enable_block_templates() {
if ( wp_is_block_theme() || wp_theme_has_theme_json() ) {
add_theme_support( 'block-templates' );
}
}
Changelog
Version | Description |
---|---|
5.8.0 | Introduced. |