wp_theme_json_data_default filter-hookWP 6.1.0

Filters the default data provided by WordPress for global styles & settings.

Usage

add_filter( 'wp_theme_json_data_default', 'wp_kama_theme_json_data_default_filter' );

/**
 * Function for `wp_theme_json_data_default` filter-hook.
 * 
 * @param WP_Theme_JSON_Data $theme_json Class to access and update the underlying data.
 *
 * @return WP_Theme_JSON_Data
 */
function wp_kama_theme_json_data_default_filter( $theme_json ){

	// filter...
	return $theme_json;
}
$theme_json(WP_Theme_JSON_Data)
Class to access and update the underlying data.

Changelog

Since 6.1.0 Introduced.

Where the hook is called

WP_Theme_JSON_Resolver::get_core_data()
wp_theme_json_data_default
wp-includes/class-wp-theme-json-resolver.php 175
$theme_json   = apply_filters( 'wp_theme_json_data_default', new WP_Theme_JSON_Data( $config, 'default' ) );

Where the hook is used in WordPress

Usage not found.