wpseek.com
A WordPress-centric search engine for devs and theme authors



wp_get_theme_data_custom_templates › WordPress Function

Since6.4.0
Deprecatedn/a
wp_get_theme_data_custom_templates ( No parameters )
Returns:
  • (array) Associative array of `$template_name => $template_data` pairs, with `$template_data` having "title" and "postTypes" fields.
Defined at:
Codex:

Returns the metadata for the custom templates defined by the theme via theme.json.



Source

function wp_get_theme_data_custom_templates() {
	return WP_Theme_JSON_Resolver::get_theme_data( array(), array( 'with_supports' => false ) )->get_custom_templates();
}